Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add sveltekit entry patterns #393

Merged
merged 6 commits into from
Dec 17, 2023
Merged

add sveltekit entry patterns #393

merged 6 commits into from
Dec 17, 2023

Conversation

thenbe
Copy link
Contributor

@thenbe thenbe commented Dec 16, 2023

This PR's adds more sveltekit entry patterns:

  1. sveltekit's two optional hooks files
  2. param matchers

Before this PR, knip reports the files as "unused files" (if they exist).

Additionally, I've expanded the pattern for vite.config.* (to help with this workaround: #346 (comment))

Copy link

vercel bot commented Dec 16, 2023

Someone is attempting to deploy a commit to a Personal Account owned by @webpro on Vercel.

@webpro first needs to authorize it.

@thenbe thenbe changed the title add sveltekit hooks as entries add sveltekit entry patterns Dec 16, 2023
@webpro
Copy link
Collaborator

webpro commented Dec 16, 2023

Thanks @thenbe! Happy to merge this.

Two remarks:

  • Any chance you can add one or two matching files to the svelte fixture? To verify they're no longer unused.
  • This PR reminds me of the vite plugin, maybe we can import the CONFIG_FILE_PATTERNS from that plugin (it's slightly more extensive) and merge it into this one?

@thenbe
Copy link
Contributor Author

thenbe commented Dec 16, 2023

Importing from the vite plugin does feel better.

I added fixture files with minimal content. Let me know if you prefer them to be empty instead.

@webpro
Copy link
Collaborator

webpro commented Dec 16, 2023

Oh if you'd want to empty them that would be great! 🙏 I wanted to clear more out in other fixtures, it's mostly noise for Knip.

@webpro webpro merged commit 7055120 into webpro-nl:main Dec 17, 2023
8 of 9 checks passed
@webpro
Copy link
Collaborator

webpro commented Dec 17, 2023

Thanks @thenbe! Much appreciated ❤️

@webpro
Copy link
Collaborator

webpro commented Dec 17, 2023

🚀 This pull request is included in v3.8.2. See Release 3.8.2 for release notes.

@webpro
Copy link
Collaborator

webpro commented Dec 17, 2023

Btw it's also here: https://knip.dev/reference/plugins/svelte

@webpro
Copy link
Collaborator

webpro commented Jan 16, 2024

🚀 This pull request is included in v4.0.0. See Release 4.0.0 for release notes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants