Rules Hub
Coding Rules Library
← Back to all rules
Rule priority, scope & exceptions
Use this to align rules with the senior-level structure (P0/P1/P2, scope, exceptions/tradeoffs).
frontend ruleP2stack specificStack: npm/package.json
dependenciesspapackaging
For an SPA, client-only bundled deps are devDependencies
In a single-page app everything bundled to the client is a build-time concern; only packages needed to serve belong in production dependencies.
PR: hegnar-bellsheep-web · org-mining-hist-2026-06Created: Jun 18, 2026
Bad example
Old codejson
| 1 | "dependencies": { "@tanstack/react-query-devtools": "^5" } |
Explanation (EN)
Objašnjenje (HR)
Good example
New codejson
| 1 | "devDependencies": { "@tanstack/react-query-devtools": "^5" } |
Explanation (EN)
Objašnjenje (HR)