Skip to content

Second order Plugins registering other plugins (like WebC) and settings reuse #3655

@mirisuzanne

Description

@mirisuzanne

Is your feature request related to a problem? Please describe.

I have a plugin that relies on WebC, and registers a number of WebC components. In order for that to be useful, I either have to register the WebC plugin inside my plugin – at which point the use cannot also register WebC components in their config – or I have to document all the imports to be copy/pasted into the user config.

Or I can provide a drill-down: pass your WebC config into my WebC config, and I'll merge them together. But that's a strange option in practice:

  eleventyConfig.addPlugin(someRandomPlugin, {
    webcComponentsNotRelatedToThisPluginAtAll: [
      'content/_includes/**/*.webc',
      'npm:somethingElse/*.webc',
    ],
  });

Describe the solution you'd like

I don't have a specific syntax in mind. I'm not sure if the solution is generic – allowing plugins to merge multiple registrations – or if it's a specific feature of WebC (in which case I might be putting this issue in the wrong place).

Describe alternatives you've considered

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions