Create a pnpm workspace
the pnpm-workspace file should like this
# pnpm-workspace.yaml
packages:
# executable/launchable applications
- 'apps/*'
# all packages in subdirs of packages/ and components/
- 'packages/*'
for now packages directtory will be empty, you may want to create the directory now for later use, by default git won't track it, to avoid this create empty .gitkeep file inside packages directory
initialize projects
frontend pnpm create vite frontend --template react-ts, if you don't have pnpm npm i -g pnpm
backend mkdir backend && cd backend then pnpm init, then install packages as before pnpm add express and ts declarations pnpm add -D @types/express
Create a pnpm workspace the pnpm-workspace file should like this
for now packages directtory will be empty, you may want to create the directory now for later use, by default git won't track it, to avoid this create empty .gitkeep file inside
packages
directoryinitialize projects
pnpm create vite frontend --template react-ts
, if you don't have pnpmnpm i -g pnpm
mkdir backend && cd backend
thenpnpm init
, then install packages as beforepnpm add express
and ts declarationspnpm add -D @types/express