An opinionated, high-velocity TypeScript monorepo manager built on `pnpm` and `tsup`. This workspace provides the scaffolding for building shared libraries, React components, and CLI tools with minimal configuration overhead.
npm install @stack-dev/cliAn opinionated, high-velocity TypeScript monorepo manager built on pnpm and tsup. This workspace provides the scaffolding for building shared libraries, React components, and CLI tools with minimal configuration overhead.
---
@stack-dev/cli globally via npm:``bash`
npm install -g @stack-dev/cli
command:`bash
stack create my-new-project
`$3
Inside the workspace, use the stack g command to create different types of modules:`bash
Generate a vanilla TypeScript library
stack g my-utils --type libraryGenerate a React library with Styled Components
stack g ui-kit --type react --style styled-componentsGenerate a Vite + React application
stack g web-app --type vite
`---
🛠 Commands
| Command | Alias | Description |
|-------------------------------|-------|----------------------------------------------|
|
stack create | | Initialize a new workspace |
| stack g | | Generate a new package, app, or config |
| stack link [name] | l | Link a local workspace package to the current directory |
| stack unlink [name] | u | Remove a local package link |---
🏗 Project Structure
This workspace is organized as follows:
-
packages/*: Shared libraries and configuration packages.
- apps/*: Deployment targets such as Vite apps, CLIs, etc.
- configs/*: Shared ESLint, Prettier, and TypeScript configuration files.---
🔧 Development Workflow
$3
To build the workspace, run:`bash
pnpm run build
`$3
To run a compiled build:`bash
pnpm start
`For development, run in watch mode:
`bash
pnpm run build --watch
`---
🛠 Smart Linking with CLI
The
@stack-dev/cli provides intelligent linking for local packages in your workspace:- Interactively link a package:
`bash
stack link
`- Link as a
devDependency:
`bash
stack link @stack-dev/core --dev
`To unlink a package:
`bash
stack unlink
`---
Documentation
Visit the individual package directories (e.g.,
packages/cli or apps`) for more specific details about their usage and configuration.