[Module API] Filter which entrypoints plugins run in
Open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 10.5k
- Forks
- 564
- PR merge metrics
- No merged PRs in 30d
Description
Feature Request
Add a way to filter which entrypoints plugins are added to.
Specifically, modify the addWxtPlugin function like so:
export default defineWxtModule((wxt) => {
addWxtPlugin(
wxt,
"wxt-module-analytics/client-plugin",
(entry /* or `group` */) => {
return true
},
);
});
The third parameter should be optional and default to the current behavior of running the plugin in all entrypoints.
Is your feature request related to a bug?
If so, add a link here. If not, write "N/A"
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the addWxtPlugin implementation and its Module API reference, especially how plugin entrypoints are currently selected. Trace the existing all-entrypoints behavior, then verify that an omitted third parameter preserves it while a predicate filters the selected entrypoints as described.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- build-system, tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 64/100