create-react-dotnet-starterkit
v0.4.1
Published
Scaffolding CLI for CodeBuddy React + Vite starterkit (auth or no-auth variants).
Downloads
104
Readme
CodeBuddy React + Vite Starterkit (auth / no-auth)
Two Vite + React + MUI starter templates plus a tiny npm create-style CLI that lets you pick whether to scaffold with auth.
How to scaffold a new app
# Prompted for auth vs no-auth
npm create react-dotnet-starterkit@latest my-app
# Force a variant
npx create-react-dotnet-starterkit my-app --auth
npx create-react-dotnet-starterkit my-app --no-authAfter generation:
cd my-app
npm install
npm run devWhat’s in each template
- auth (
templates/auth): zustandAuthStore,ProtectedRoute, token refresh helpers, and auth-enabledApiClient. Env sample:.env.exampleincludes API URL, auth flags, and develop flag. - no-auth (
templates/no-auth): public-only routing, simplifiedApiClientwithout tokens, no auth deps. Env sample trimmed to just API URL and develop flag.
Common stack:
- React 18 + TypeScript + Vite 5 + MUI 5
- Path aliases (
@/), eslint/prettier configs, vitest setup hooks (tests not included by default) - Dynamic
site.webmanifestvia Vite plugin
Do we need to publish?
Yes, to use npm create react-dotnet-starterkit@latest from anywhere, you publish this package to npm (or your private registry).
Typical flow to publish to npm:
- Set the package name (already
create-react-dotnet-starterkit) and version in rootpackage.json. npm loginnpm publish --access public(or--access restrictedif using a private scope/registry)
If you don’t want to publish, you can still scaffold locally by running the CLI directly:
node scripts/init.js my-app --author by using npm pack and installing from the generated tarball.
