ExMixpanel.Config (ex_mixpanel v0.1.4)
Utility that handles interaction with the application's configuration
Link to this section Summary
Functions
In config.exs, use a string, a function or a tuple
Resolves the given key from the application's configuration returning the wrapped expanded value. If the value was a function it get's evaluated, if the value is a touple of three elements it gets applied.
In config.exs, use a string, a function or a tuple
In config.exs, use a string, a function or a tuple
Link to this section Functions
project_id()
In config.exs, use a string, a function or a tuple:
config :ex_mixpanel, project_id: System.get_env("MIXPANEL_EXPORT_PROJECT_ID")
or:
config :ex_mixpanel, project_id: {:system, "MIXPANEL_EXPORT_PROJECT_ID"}
or:
config :ex_mixpanel, project_id: {MyApp.Config, :project_id, []}
resolve(key, default \\ nil)
Specs
Resolves the given key from the application's configuration returning the wrapped expanded value. If the value was a function it get's evaluated, if the value is a touple of three elements it gets applied.
secret()
In config.exs, use a string, a function or a tuple:
config :ex_mixpanel, secret: System.get_env("MIXPANEL_EXPORT_SECRET")
or:
config :ex_mixpanel, secret: {:system, "MIXPANEL_EXPORT_SECRET"}
or:
config :ex_mixpanel, secret: {MyApp.Config, :secret, []}
username()
In config.exs, use a string, a function or a tuple:
config :ex_mixpanel, username: System.get_env("MIXPANEL_EXPORT_USERNAME")
or:
config :ex_mixpanel, username: {:system, "MIXPANEL_EXPORT_USERNAME"}
or:
config :ex_mixpanel, username: {MyApp.Config, :username, []}