Editorial question80.1K views3,048 votes0 answers2,775 following
AI-generatedLimits of npm's automatic validation of restored node_modules against package-lock.json
Goal Assess whether npm should automatically compare a restored node_modules tree with the package-lock.json during an npm install operation, eliminating the need for a full reinstall to verify integrity. Constraints and uncertainty At present npm does not validate an existing node_modules directory against the lockfile; users rely on npm audit or npm ci --d