-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
fix(gatsby): validate local plugin options schema #29787
fix(gatsby): validate local plugin options schema #29787
Conversation
Will need to handle when using {
resolve: 'E:\\Development\\Contrib\\gatsby\\packages\\gatsby\\src\\bootstrap\\load-plugins\\__tests__\\fixtures\\local-plugin\\index.js',
options: { optionalString: 1234 }
} So the following line in
|
It looks like there's a snapshot failing unrelated to this PR; it was failing in I took a cue from |
I am not sure if an e2e test is more appropriate for this or my integration test, let me know 😄 |
I realized Will continue investigating proposed fix tomorrow. Fixing |
Hi, thanks for the PR!
We'll handle this :)
Integration test is fine
For local development we use yarn workspaces and our own CLI So to copy your changes to the integration test, you can run |
@LekoArts Thanks, that worked nicely 👍 |
93f1de9
to
5bce9d4
Compare
I think the tests that are failing are unrelated; I see the same ones failing in other approved PRs too. 😞 But this should be ready to go. |
44d5806
to
b59e5fc
Compare
b59e5fc
to
f0a63a9
Compare
@LekoArts Anything else I need to do? Thanks! |
Is there anyway this can be pushed as the solution has already been provided as a PR? |
I'll be recording my demos next week and this would be amazing to get in so I don't have to keep using local dev fork 😄 |
…plugin-schema-29785-v3
Hey @kamranayub - sorry for the delay here, we were (and are) busy with follow-up work of the v3 launch. |
Awesome, thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Description
Fix for
pluginOptionsSchema
not being validated for locally resolved plugins.Changes
resolvePlugins
when validating optionsTasks
require.resolve
)require.resolve
)Backport for v2 🆘 🤚 Need assistance/guidance with this.Documentation
Related Issues
Fixes #29785
Related to #27242