AshGleam.DomainExtension (ash_gleam v0.3.2)

Copy Markdown

Domain extension that generates code-interface functions for Gleam update actions.

Usage

defmodule MyApp.MyDomain do
  use Ash.Domain,
    otp_app: :my_app,
    extensions: [AshGleam.DomainExtension]

  gleam_updates do
    resource MyApp.Todo do
      define_gleam_update :mark_completed, action: :update
    end
  end
end

This generates mark_completed/1-3 and mark_completed!/1-3 on the domain module.

Summary

Functions

gleam_updates(body)

(macro)