Skip to content

feat: raycast plugin#1619

Merged
webpro merged 3 commits intowebpro-nl:mainfrom
TkDodo:feature/raycast
Mar 17, 2026
Merged

feat: raycast plugin#1619
webpro merged 3 commits intowebpro-nl:mainfrom
TkDodo:feature/raycast

Conversation

@TkDodo
Copy link
Contributor

@TkDodo TkDodo commented Mar 14, 2026

Hi 👋

I recently wrote a raycast plugin, but knip doesn’t know about its file structure yet, so I added a plugin:

Raycast uses the commands section in package.json to find commands:

  • commands go into src/name-of-the-command{.ts,.tsx,.js,.jsx}
  • tool are located in src/tools/name-of-the-tool{.ts,.tsx,.js,.jsx}

Question: Only the default export of commands and tools should be seen as used by knip - I haven’t found a way to express this though. Is this something that knip supports? I think right now the whole file becomes an entry point ...

Note: This PR was done with AI assistance.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Mar 14, 2026

Open in StackBlitz

npm i https://pkg.pr.new/knip@1619
npm i https://pkg.pr.new/@knip/language-server@1619
npm i https://pkg.pr.new/@knip/mcp@1619

commit: fb2c2c2

@TkDodo TkDodo marked this pull request as ready for review March 15, 2026 09:38
@webpro webpro merged commit 52c77ee into webpro-nl:main Mar 17, 2026
30 checks passed
@webpro
Copy link
Member

webpro commented Mar 17, 2026

Thank you!

Question: Only the default export of commands and tools should be seen as used by knip - I haven’t found a way to express this though. Is this something that knip supports? I think right now the whole file becomes an entry point ...

There is no way to express this. Also see #1442 for an outstanding issue/idea.

@webpro
Copy link
Member

webpro commented Mar 18, 2026

🚀 This pull request is included in v5.88.0. See Release 5.88.0 for release notes.

Using Knip in a commercial project? Please consider becoming a sponsor.

@TkDodo TkDodo deleted the feature/raycast branch March 18, 2026 08:41
@TkDodo
Copy link
Contributor Author

TkDodo commented Mar 18, 2026

There is no way to express this. Also see #1442 for an outstanding issue/idea.

yeah this is a good idea. I think most entry points need default exports, but customized named exports sounds good too.

@webpro
Copy link
Member

webpro commented Mar 19, 2026

🚀 This pull request is included in v6.0.0-2. See Release 6.0.0-2 for release notes.

Using Knip in a commercial project? Please consider becoming a sponsor.

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.

2 participants