Snaplet for using Persistent in snap applications
Switch branches/tags
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
example
resources
src/Snap/Snaplet
.ghci
.gitignore
.travis.yml
CHANGELOG.md
LICENSE
README.md
Setup.hs
schema.txt
snaplet-persistent.cabal
stack.yaml

README.md

Build Status

This package makes it easier to integrate your snap applications with databases using persistent. It also includes a backend for the auth snaplet defining how users should be stored in your database.

Adding the snaplet to your application is simply a matter of adding the snaplet to your application’s state data type and initializing it appropriately in your application initializer. After you do this, when you run your application for the first time, the snaplet will automatically install a default configuration file that looks like this.

postgre-con-str = "host='localhost' dbname='snap-test' user='guest' password='password1'" postgre-pool-size = 3

Then you can edit this file as you see fit. The auth backend works similarly with its own set of config options.