Boilerplate for full-stack typescript project. Create React App + Fastify API in monorepo.
This project require number of tools available.
Repo provides an init script that will bootstrap baseline env files It will check if the user has docker and docker-compose installed. For OAuth to work, google and facebook configs need to updated in packages/api .env
Clone repository
git clone https://github.com/chyzwar/modern-stack.git my-project
cd my-project
Initialize env
yarn initialize
Start project
yarn start
You can now visit: http://project.localhost
Setup auth provider(optional)
Update packages/api/.env with client id and client secrets
Based on fastify. It is a modern node.js framework with a good ecosystem of plugins. Postgres is used for database and managed by Sequelize ORM.
- migration and seeding with sequelize
- authentication with JWT and cookies
- integration with oauth2: Google, Facebook
- logging with pino
- hot reload with nodemon
Standard typescript application based on create-react-app. Basic authentication under /login. Use Material-UI for Login page and react-router for frontend routes.
- material-ui components
- react-router routing
- basic auth integration
There is also a secondary UI application admin-ui. There is not much done beside bootstrap. It can be removed or used for the different business use case.
Unit testing is provided by Jest. There few test examples (not enough). For API test there are an example of testing leveraging fastify http injection
The project provides basic automation pipeline using Github actions. Dependabot scan weekly for outdated packages and creates automatic PRs.
Project use yarn workspaces to support hoisting dependencies and managing packages in monorepo. Husky and lint staged provide baseline git hooks. ESlint is configured with more strict airbnb config. Project will is configured with docker-compose to manage multiple containers.
- Add classic auth (login + password)
- E2E tests setup using cypress
- Deployment strategy AWS ECS/Fargate/Zeit
- Audit security settings JWT/Cookies/Headers
- Create an basic admin application