Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

ImSeanConroy/cookbook

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

50 Commits

Repository files navigation

Cookbook: all your recipes in one place

A full-stack recipe management app built with the PERN stack (PostgreSQL, Express, React, Node.js).
Save, organize, and discover recipes all in one place — built for food lovers and home cooks.

Project Colors Demo

Table of Contents

About the Project

Cookbook is a modern, full-stack web app that lets users create, store, and share their favorite recipes.
It features a fast React frontend, a Node/Express API, and a PostgreSQL database for reliable data storage.

Whether you’re tracking your family’s secret recipes or exploring new cuisines, Cookbook keeps everything organized and searchable.

Features

  • Create, edit, and delete recipes (Under Development).
  • Search recipes by name and subtitle.
  • Filter recipes by cuisine, cooktime, difficulty, meal type and dietary requirements.
  • Simple, responsive UI built with React, Tailwind and Shadcn.
  • Dockerized backend and database setup for easy development.

Getting Started

Prerequisites

Before getting started, ensure you have the following installed:

Option 1 — Run with Docker (Recommended)

This runs PostgreSQL, Backend, Frontend, and PGAdmin in containers:

  1. Clone the repository:
git clone https://github.com/imseanconroy/cookbook.git
cd cookbook
  1. Start the development environment:
docker compose --env-file docker/env/.env.dev -f docker/compose/docker-compose.dev.yaml up --build -d
  1. Run database migrations:
docker compose --env-file docker/env/.env.dev -f docker/compose/docker-compose.dev.yaml exec backend npm run migrate:up
  1. Seed the database (Optional):
docker compose --env-file docker/env/.env.dev -f docker/compose/docker-compose.dev.yaml exec backend npm run seed
  1. Access the application:
  1. To stop the application:
docker compose --env-file docker/env/.env.dev -f docker/compose/docker-compose.dev.yaml down -v

Option 2 — Run Manually (Without Docker)

This runs PostgreSQL, Backend, Frontend, and PGAdmin in containers:

  1. Clone the repository:
git clone https://github.com/imseanconroy/cookbook.git
cd cookbook
  1. Install backend dependencies:
cd backend
npm install
  1. Configure backend environment variables:
PORT=8000
NODE_ENV=development
READ_ONLY=false
FRONTEND_ORIGIN=http://localhost:5173
POSTGRES_PASSWORD=<database_password>
POSTGRES_USER=<database_user>
POSTGRES_DB=<database_name>
POSTGRES_PORT=5432
POSTGRES_HOST=localhost
  1. Create the database tables and seed the database:
DATABASE_URL=postgres://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DB} npm run migrate:up && npm run seed
  1. Start backend express server:
npm run dev
  1. Install frontend dependencies:
cd frontend
npm install
  1. Configure frontend environment variables:
VITE_API_BASE_URL=http://localhost:8000
  1. Start the frontend react application:
npm run dev

Development and Testing

Run all backend tests with the following command:

cd backend
npm run test

Development Plan and Improvements

This section outlines upcoming features and improvements:

  1. User Features:

    • Add ability to create, update and delete recipes from the fronted.
    • Add local bookmarking and "favorites" functionality.
  2. Testing and Quality Assurance:

    • Expand test coverage for frontend components.
  3. Documentation:

    • Create a detailed API reference.

Feel free to suggest additional improvements by opening an issue.

Project Structure

cookbook/
├── frontend/ # React application for the user interface
├── backend/ # Express.js server with PostgreSQL integration
│ ├── migrations/ # Database migration files
│ ├── test/ # Backend tests
│ ├── src/ # Backend source code
│ │ ├── config/ # Database and environment configurations
│ │ ├── controllers/ # API request handlers
│ │ ├── middleware/ # Request processing logic
│ │ ├── repositories/ # Database queries and schema models
│ │ ├── routes/ # API endpoint definitions
│ │ ├── services/ # Core business logic
│ │ └── util/ # Utility functions (e.g., validation, logging)
├── docker/ # Docker configuration files
└── README.md # Project documentation

Contributing

Contributions are welcome. Please open an issue or fork the repository, create a new branch (feature/your-feature-name) and submit a pull request for any enhancements or bug fixes.

License

This project is licensed under the MIT License - see the LICENSE file for information.

Support

If you are having problems, please let me know by raising a new issue.

About

All your recipes in one place

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

AltStyle によって変換されたページ (->オリジナル) /