1 | initial version |
To use pnpm to build a single workspace only, you can follow these steps:
Open your terminal and navigate to the root directory of your project.
Run the pnpm install
command to install all the dependencies in all the workspaces.
Run the pnpm run build
command followed by the name of the workspace you want to build. For example, if your project has a workspace named "frontend", you can run the following command:
pnpm run build --filter frontend
This will build only the "frontend" workspace.
Once the build process is complete, you can find the built files in the "dist" folder of the "frontend" workspace.
Note: pnpm uses the --filter
option to specify which workspace to build. If you want to build multiple workspaces, you can separate their names with commas. For example:
pnpm run build --filter frontend,backend
This will build both the "frontend" and "backend" workspaces.