mcordova47 / recipe-book

App for viewing and editing recipes

Home Page:https://myrecipebook.netlify.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

recipe-book

Netlify Status

A UI for Managing Recipes

Features

  • List view of all recipes by category
  • Detail views of each recipe
  • Filter recipes with the search box
  • Calculates cost of recipes based on ingredients
  • Recipe directions support markdown for basic text formatting as well as tooltips for referenced ingredients
  • Recipes can be used as ingredients, in which case they will render as a link to the referenced recipe
  • Side-panel to quickly scan for recipes

TODO

  • View for editing recipes
  • View for editing ingredients
  • Multi-user support

Development

The front end is written in Purescript with purescript-pux. The server side is written in Haskell.

Server

Run server

$ stack build --exec api

DB Migrations

Migrations are handled with golang-migrate

$ migrate -path /path/to/server/migrations -database $env:DATABASE_URL up

Client

Generate PureScript types

$ stack build --exec bridge

Install dependencies

$ npm install

Dev build with hot module reloading

  $ npm start

Production

The front end is hosted on netlify. Builds are deployed on each commit to master.

I'm currently experiencing problems with netlify, so the ad-hoc way for now is using github pages (https://mcordova47.github.io/recipe-book):

git push --delete origin gh-pages
git branch -D gh-pages
git checkout -b gh-pages
cd client
npm run build-production
cd ..
git add -f client/dist
git commit
git subtree push --prefix client/dist origin gh-pages

The server is hosted on heroku. To deploy:

git subtree push --prefix server heroku master

If this fails, may need to:

git push heroku `git subtree split --prefix website master`:master --force

To migrate production:

migrate -path migrations -database $(heroku config:get DATABASE_URL --app recipebook-api) up

About

App for viewing and editing recipes

https://myrecipebook.netlify.com


Languages

Language:PureScript 62.3%Language:Haskell 19.9%Language:JavaScript 12.3%Language:Dhall 4.1%Language:TSQL 0.8%Language:HTML 0.5%