- This project brings the blazing-fast DX of a modern JS build system to codebases reliant on Webpack.
- It also implements a convenient monorepo setup that is extensible to any number of frontend clients or backend services.
- Transpilation:
SWC- ~60x speed improvement over
babel,tsc. Better performance thanesbuild. - Supports HMR with
react-refresh(unlikeesbuild-loader).
- ~60x speed improvement over
- Minification:
ESBuild
- Monorepo setup with
Yarn Workspaces, TypeScript path aliases,tsconfig-paths-plugin - React SPA, Express server, Redux state slices all organized as independent subrepos.
- Simple code sharing (types, constants, modules) between cross-platform frontend clients (mobile, electron) and backend services.
- Frontend:
React,Redux Toolkit,RTK Query,Tailwind CSS - Backend:
Express.js,ts-node,PostgreSQL,Docker Compose - Express middleware:
express-rate-limit,express-slow-down,helmet,hpp,nocache,morgan - Build:
Webpack - Linters:
ESLint,Prettier,Headwind,TypeScript Import Sorter - Testing:
Jest,React Testing Library
Click the green Use this Template button on GitHub, or run this command.
git clone --depth 1 https://github.com/MajorLift/typescript-fullstack-monorepo-starterYarn is required to use this template.
npm install --global yarnDocker is used to launch the Postgres DB. Download it here.
- To run the project in dev mode, navigate to the project directory and run:
yarn dev- This will concurrently spawn...
- The React app at http://localhost:8080
- The Express server at http://localhost:3000
- The Postgres DB at http://localhost:5333
- To generate a production build
yarn build- To preview the production build with
ts-noderunning onnodemon
yarn start- To clean up or reload the DB
yarn docker-clean
yarn docker-reload- To run the linter
yarn lint- To run the test suite
yarn test