Using Miso
This guide explains how to interact with Miso in your projects. Learn how to set up Miso, run commands from anywhere in your project, and understand what to do when things go wrong.
Running Commands from Anywhere
You can run Miso commands from any subdirectory within your project. Miso automatically finds your project root by looking for miso.json, lockfiles, or node_modules in parent directories.
Setting Up a Project (miso init)
Run miso init to set up Miso in your project. This creates a miso.json configuration file.
What Happens
- Project name - You’ll be prompted to name your project (defaults to your directory name)
- Package manager selection - Choose your package manager from the list (bun, npm, pnpm, or yarn)
- Configuration created - Miso creates
miso.jsonin the current directory - Package manager init - If
package.jsondoesn’t exist, Miso runs your selected package manager’sinitcommand
Working with Monorepos
Miso works great in monorepo structures. You can run commands from any subdirectory, and Miso will find your project configuration at the root.
Example
my-monorepo/
├── miso.json
├── package.json
└── packages/
└── frontend/
└── src/
└── components/If you’re in packages/frontend/src/components/ and run miso add react:
- Miso finds your
miso.jsonat the monorepo root - The package manager command runs from your current directory (
packages/frontend/src/components/) - This means packages are added to the correct location in your monorepo structure
Key point: Keep one miso.json at your monorepo root, and run Miso commands from anywhere in your project structure.
Editing Your Configuration
You can edit miso.json directly to change settings:
- Switch package managers - Change the
package-managerfield - Change scripts folder path - Update the
scriptsfield (defaults to./scripts) - Update project name - Change the
project-namefield
No need to run miso init again after editing the file.