You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Not using production mode may hide issues, as this PR shows. At the same time, some consider it good to be strict in fast-pacing projects, and others only annoying. Let me know if you want me to add it to CI anyway.
Bumped Knip
A package.json#scripts.postinstall no longer requires production dependencies (simple-git-hooks, lint-staged), so it won't flag these in production mode
Did not actually add pnpm knip --production to CI, but prepared for that:
Re-added a bunch of exclamation marks
Removed unused exports
Added @internal for exports only imported by tests
none of the dependencies in a nuxt project are actually used in prod so I tend to separate dev vs prod deps between lint/tooling stuff and the stuff required to actually build nuxt (which includes uno)
Production mode isn't about dependencies actually being installed or imported at runtime. It's about what's imported from production source code (regardless of getting bundled or not).
But yeah, some "faux production entries" are a result of that strategy, and that's fine from a Knip perspective, provided the ! suffixes everywhere are acceptable.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Not using production mode may hide issues, as this PR shows. At the same time, some consider it good to be strict in fast-pacing projects, and others only annoying. Let me know if you want me to add it to CI anyway.
package.json#scripts.postinstallno longer requires productiondependencies(simple-git-hooks, lint-staged), so it won't flag these in production modepnpm knip --productionto CI, but prepared for that:Removed unused exports@internalfor exports only imported by testsNo need to decide/fix now, as the changes don't affect how Knip is currently used in default/dev mode (but I'd be happy to if you agree!).