View Source Pow.Extension.Base behaviour (Pow v1.0.36)
Used to set up extensions to enable parts of extension for auto-discovery.
This exists to prevent unnecessary Code.ensure_compiled/1
calls, and will
let the extension define what modules it has.
Usage
defmodule MyCustomExtension do
use Pow.Extension.Base
@impl true
def ecto_schema?(), do: true
end
Summary
Functions
Checks whether an extension has a certain module.
Checks whether an extension has a certain module that has a __using__/1
macro.
Callbacks
Functions
Checks whether an extension has a certain module.
If a base extension module doesn't exist, or is configured improperly,
Code.ensure_compiled/1
will be used instead to see whether the module
exists for the extension.
Checks whether an extension has a certain module that has a __using__/1
macro.
This calls has?/2
first, If a base extension module doesn't exist, or is
configured improperly, Kernel.macro_exported?/3
will be used instead to
check if the module has a __using__/1
macro.