Skip to content

Latest commit

History

16 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

Ecto.Atom

Provide an Ecto custom type Ecto.Atom to manage :atom.

Installation

If available in Hex, the package can be installed by adding ecto_atom to your list of dependencies in mix.exs:

defdepsdo[{:ecto_atom,"~> 1.0.0"}]end

Use

defmoduleMyApp.UserdouseMyApp.Web,:model@primary_key{:id,:binary_id,autogenerate: true}@derive{Phoenix.Param,key: :id}schema"users"dofield:email,:stringfield:provider,Ecto.Atom# :github => 'github' in DBfield:uid,:stringfield:token,:string...endend

Documentation can be generated with ExDoc and published on HexDocs. Once published, the docs can be found at https://hexdocs.pm/ecto_atom.

About

Ecto atom

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages