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

Documentation on nested plugins? #4572

Closed
pauldotknopf opened this issue Mar 16, 2018 · 6 comments
Closed

Documentation on nested plugins? #4572

pauldotknopf opened this issue Mar 16, 2018 · 6 comments
Labels
help wanted Issue with a clear description that the community can help with. stale? Issue that may be closed soon due to the original author not responding any more. type: documentation An issue or pull request for improving or updating Gatsby's documentation

Comments

@pauldotknopf
Copy link

plugins: [

Is there guidance on how they work and when to use them?

@m-allanson
Copy link
Contributor

@pauldotknopf There's not a lot on nested plugins, maybe have a look at the Plugin Authoring Guide.

Nested plugins can be used to extend the capabilities of the parent plugin. As an example, all of Gatsby's gatsby-remark-x plugins extend the gatsby-transformer-remark plugin.

@KyleAMathews
Copy link
Contributor

Any plugin can have its own plugins. But the parent plugin has to be expecting this and have code to call the code from the sub-plugin for this to have any effect otherwise nothing happens. gatsby-transformer-remark is the only plugin I know that does this currently. Here is where it let's each sub-plugin mutate the markdown AST

// Use Bluebird's Promise function "each" to run remark plugins serially.

@jkjustjoshing
Copy link
Contributor

Can we re-open this? This seems like a pretty important thing to document inside the Plugin Authoring Guide.

I'm writing an extension right now that is taking nodes defined by gatsby-source-filesystem and transforming them. Should gatsby-source-filesystem be a nested plugin of my transformer plugin? I do not know the answer to that question, and the docs do not currently provide an answer. The only way I can answer that question right now is digging into the source code of gatsby-transformer-remark.

@jkjustjoshing jkjustjoshing reopened this Apr 26, 2019
@jkjustjoshing jkjustjoshing added the type: documentation An issue or pull request for improving or updating Gatsby's documentation label Apr 26, 2019
@gatsbot
Copy link

gatsbot bot commented May 17, 2019

Hiya!

This issue has gone quiet. Spooky quiet. 👻

We get a lot of issues, so we currently close issues after 30 days of inactivity. It’s been at least 20 days since the last update here.

If we missed this issue or if you want to keep it open, please reply here. You can also add the label "not stale" to keep this issue open!

As a friendly reminder: the best way to see this issue, or any other, fixed is to open a Pull Request. Check out gatsby.dev/contributefor more information about opening PRs, triaging issues, and contributing!

Thanks for being a part of the Gatsby community! 💪💜

@gatsbot gatsbot bot added the stale? Issue that may be closed soon due to the original author not responding any more. label May 17, 2019
@jkjustjoshing jkjustjoshing added not stale and removed stale? Issue that may be closed soon due to the original author not responding any more. labels May 17, 2019
@marcysutton marcysutton added the help wanted Issue with a clear description that the community can help with. label Jun 25, 2019
@github-actions
Copy link

github-actions bot commented Dec 9, 2019

Hiya!

This issue has gone quiet. Spooky quiet. 👻

We get a lot of issues, so we currently close issues after 30 days of inactivity. It’s been at least 20 days since the last update here.
If we missed this issue or if you want to keep it open, please reply here. You can also add the label "not stale" to keep this issue open!
As a friendly reminder: the best way to see this issue, or any other, fixed is to open a Pull Request. Check out gatsby.dev/contribute for more information about opening PRs, triaging issues, and contributing!

Thanks for being a part of the Gatsby community! 💪💜

@github-actions github-actions bot added the stale? Issue that may be closed soon due to the original author not responding any more. label Dec 9, 2019
@github-actions
Copy link

Hey again!

It’s been 30 days since anything happened on this issue, so our friendly neighborhood robot (that’s me!) is going to close it.
Please keep in mind that I’m only a robot, so if I’ve closed this issue in error, I’m HUMAN_EMOTION_SORRY. Please feel free to reopen this issue or create a new one if you need anything else.
As a friendly reminder: the best way to see this issue, or any other, fixed is to open a Pull Request. Check out gatsby.dev/contribute for more information about opening PRs, triaging issues, and contributing!

Thanks again for being part of the Gatsby community! 💪💜

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Issue with a clear description that the community can help with. stale? Issue that may be closed soon due to the original author not responding any more. type: documentation An issue or pull request for improving or updating Gatsby's documentation
Projects
None yet
Development

No branches or pull requests

7 participants