nx-vite-react-ts-mantine-boilerplate
nx-vite-react-ts-mantine-boilerplate copied to clipboard
NX monorepository with: Vite, GraphQL / Apollo, Typescript, Storybook / CSS Modules / Mantine
NX monorepo boilerplate with React + Vite + TypeScript + Mantine
Getting Started
Prerequisites
# Install pnpm
npx pnpm add -g pnpm
# Install NX
npm install -g nx
# Init project
pnpm run init-project
Development
- Read how to create GitHub access token
- Add
.envinto./cp ./env.example ./.env - Add
.env.localinto./packages/graphql/.env.local
and add your GitHub token (see step 1)cp ./packages/graphql/env.example ./packages/graphql/.env.local - Add
.env.localto./apps/main/.env.local
and add your GitHub token (see step 1)cp ./apps/main/env.example ./apps/main/.env.local - [Optional step] Generate code from GraphQL schema
pnpm codegen:graphql - Start the app
and open the page http://localhost:3000/pnpm dev
Examples
App screenshots
Desktop version
Mobile version
Features
- Nx 16
- React 18
- Mantine 7
- Storybook 7
- TypeScript
- Vite 5
- Vitest
- React Testing Library
- Cypress
- ESLint
- HMR (Hot Module Replacement)
License
This code is licensed under the MIT License. You can find the license file here.