-
Notifications
You must be signed in to change notification settings - Fork 63
Open
Description
Dodam że pracuje póki co tylko z VsCode i weszły nowe funkcje związane z MCP. Skłoniło mnie to do nakreślenia kontekstu dla agenta że używam pnpm, a nie npm w projekcie. Oto one:
Project Commands Explanation
Scripts in package.json
Development Commands
pnpm dev: Starts the Vite development server for local development. Automatically rebuilds and reloads the app on file changes.pnpm build: Builds the project for production using Vite. Outputs optimized static assets to thedistdirectory.pnpm preview: Serves the production build locally for testing. Useful for verifying the build before deployment.
Linting and Code Quality
pnpm lint: Runs ESLint to check for code quality issues and automatically fixes them where possible. Ignores files specified in.gitignore.
Updated Project Package Management Rules
Dependency Management
- Use
pnpmfor all dependency management tasks:- Install dependencies:
pnpm install - Add a new dependency:
pnpm add <package-name> - Add a dev dependency:
pnpm add -D <package-name> - Remove a dependency:
pnpm remove <package-name>
- Install dependencies:
Lockfile Management
- Always commit the
pnpm-lock.yamlfile to version control to ensure consistent dependency resolution across environments.
Security
- Use
pnpm auditto check for vulnerabilities in dependencies and address them promptly.
Versioning
- Add the following to
.npmrcto ensure exact versions are installed:save-exact=true
CI/CD Optimization
- Use
pnpm install --frozen-lockfilein CI/CD pipelines to ensure consistent builds.
Dependency Tree Optimization
- Run
pnpm dedupeperiodically to optimize the dependency tree and reduce duplication.
Scripts Update
- Ensure all scripts in
package.jsonusepnpmcommands:"scripts": { "install": "pnpm install", "dev": "pnpm dev", "build": "pnpm build", "lint": "pnpm lint" }
Documentation
- Update the README file to include instructions for using
pnpmin the project.
Environment Variables
- Store sensitive data and configuration in a
.envfile and load it usingdotenvor similar tools.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels