Put something useful in the README

This commit is contained in:
James Eversole 2024-10-21 17:59:50 -05:00
parent 77131c4add
commit 415b1dc58e

View File

@ -8,4 +8,29 @@ A work in progress Nix starting template for web projects utilizing
- [PostgreSQL](https://www.postgresql.org/)
- [Servant](https://github.com/haskell-servant/servant)
The repository has a simple CRUD implementation of a "Users" API which demonstrates how to use included effects, create your own effects, and bubble errors to Servant's `ServerError` type.
The repository has a simple CRUD implementation of a "Users" API which demonstrates how to use included effects, create your own effects, write/compose HTML using Lucid, and bubble errors to Servant's `ServerError` type.
How to navigate this codebase (as of revision 77131c4a):
- Core
- Application data types
- Effect definitions
- Utility function for lifting IO to effectful's IOE
- Database
- Database effect handlers
- Table definitons as functions
- Helper functions for constructing SQL queries
- Handlers
- Request handlers in the Eff monad
- Logger
- Logging implementation using the Database effect for logging to PSQL
- Logging implementation to stdout
- Main
- Application entry point and initialization
- Creates a PostgreSQL connection pool to include in the Reader effect
- Effect stack runner for real database interactions
- Debugging effect stack that mocks database interactions and logs to stdout instead
- Routes
- Type level route definitions for Servant
- Views
- Lucid2 HTML templating and composition functions