A SQLite data layer for Ash Framework
Find a file
2023-09-23 01:32:12 -04:00
.github init: copy and gouge ash_postgres 2023-09-22 22:52:22 -04:00
.vscode init: copy and gouge ash_postgres 2023-09-22 22:52:22 -04:00
config improvement: get at least one test passing 2023-09-23 01:32:12 -04:00
documentation init: copy and gouge ash_postgres 2023-09-22 22:52:22 -04:00
lib improvement: get at least one test passing 2023-09-23 01:32:12 -04:00
logos init: copy and gouge ash_postgres 2023-09-22 22:52:22 -04:00
priv improvement: get at least one test passing 2023-09-23 01:32:12 -04:00
test improvement: get at least one test passing 2023-09-23 01:32:12 -04:00
.check.exs init: copy and gouge ash_postgres 2023-09-22 22:52:22 -04:00
.credo.exs init: copy and gouge ash_postgres 2023-09-22 22:52:22 -04:00
.formatter.exs improvement: get at least one test passing 2023-09-23 01:32:12 -04:00
.gitignore improvement: get at least one test passing 2023-09-23 01:32:12 -04:00
.tool-versions init: copy and gouge ash_postgres 2023-09-22 22:52:22 -04:00
LICENSE init: copy and gouge ash_postgres 2023-09-22 22:52:22 -04:00
mix.exs improvement: get at least one test passing 2023-09-23 01:32:12 -04:00
mix.lock improvement: get at least one test passing 2023-09-23 01:32:12 -04:00
README.md init: copy and gouge ash_postgres 2023-09-22 22:52:22 -04:00

AshSqlite

Elixir CI License: MIT Coverage Status Hex version badge

DSL

See the DSL documentation in AshSqlite.DataLayer for DSL documentation

Usage

Add ash_qlite to your mix.exs file.

{:ash_sqlite, "~> 0.1.0"}

To use this data layer, you need to chage your Ecto Repo's from use Ecto.Repo, to use Sqlite.Repo. because AshSqlite adds functionality to Ecto Repos.

Then, configure each of your Ash.Resource resources by adding use Ash.Resource, data_layer: AshSqlite.DataLayer like so:

defmodule MyApp.SomeResource do
  use Ash.Resource, data_layer: AshSqlite.DataLayer

  sqlite do
    repo MyApp.Repo
    table "table_name"
  end

  attributes do
    # ... Attribute definitions
  end
end

Generating Migrations

See the documentation for Mix.Tasks.AshSqlite.GenerateMigrations for how to generate migrations from your resources

Contributors

Ash is made possible by its excellent community!

Become a contributor