EctoInterface (ecto_interface v8.0.0)

EctoInterface is a suite of commonly defined APIs for Ecto-based models. Almost all of these came from the normal generated content in a new phoenix project, simply unifying and expanding on that suite.

Summary

Functions

Using this expression in your context module

Functions

__using__(options)

(macro)

Using this expression in your context module:

use(EctoInterface,
  source: Product,
  plural: :products,
  singular: :product,
  pubsub: true
)

Will automatically define a whole suite of functions for that schema.

expand_alias(alias, env)