Commanded can be installed from hex as follows.
-
Add
commanded
to your list of dependencies inmix.exs
:def deps do [{:commanded, "~> 0.19"}] end
-
Optionally add
jason
to makeCommanded.Serialization.JsonSerializer
available:def deps do [{:jason, "~> 1.1"}] end
-
Fetch mix dependencies:
$ mix deps.get
-
Define a Commanded application module for your app, see the "Application" guide for details.
defmodule MyApp.Application do use Commanded.Application, otp_app: :my_app end
-
Configure one of the supported event stores by following the "Choosing an Event Store" guide.