Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

feat: new API #18

Merged
merged 7 commits into from
Dec 29, 2020
Merged

feat: new API #18

merged 7 commits into from
Dec 29, 2020

Conversation

angeloashmore
Copy link
Owner

This PR changes the API of gatsby-node-helpers to support Gatsby's current API.

All public exports are documented with full TypeScript types available.

Breaking Changes

  • Removes createNodeFactory middleware
    Transform your nodes before passing to the resulting createNodeFactory function. If you currently are using a middleware function, move the function to a variable and call your node with the function before the createNodeFactory function.

  • Gatsby Node helper functions must be provided
    createNodeId and createContentDigest from Gatsby's Node APIs must be provided to createNodeHelpers. This library was created before any helpers were provided and handled ID and content digest generation internally. Now that Gatsby provides a standard function for both, they should be used.

This was referenced Dec 29, 2020
@angeloashmore angeloashmore merged commit f8ffaf0 into master Dec 29, 2020
@angeloashmore angeloashmore deleted the aa/ts branch December 29, 2020 04:14
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant