Last active
March 14, 2018 23:18
-
-
Save desmondmonster/03f04e73d0ed809ff3666c5b2fa9e03d to your computer and use it in GitHub Desktop.
Application With Worker
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defmodule YourApp.Application do | |
use Application | |
def start(_type, _args) do | |
import Supervisor.Spec | |
children = [ | |
{Task.Supervisor, name: YourApp.AccountSetupSupervisor} | |
] | |
opts = [strategy: :one_for_one, name: YourApp.Supervisor] | |
Supervisor.start_link(children, opts) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment