Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The syntax for declaring it, sorry


What's the equivalent of this: https://hexdocs.pm/elixir/supervisor-and-application.html

    defmodule KV.Supervisor do
      use Supervisor

      def start_link(opts) do
        Supervisor.start_link(__MODULE__, :ok, opts)
      end

      @impl true
      def init(:ok) do
        children = [
          KV.Registry
        ]

        Supervisor.init(children, strategy: :one_for_one)
      end
    end
In ergo


I'm not the person you're replying to, but this left me with more questions than answers, haha. Can you expand on what you mean?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: