v4.2 Release Notes
Welcome to gatsby@4.2.0
release (November 2021 #2)
Key highlights of this release:
Also check out notable bugfixes.
Bleeding Edge: Want to try new features as soon as possible? Install gatsby@next
and let us know
if you have any issues.
gatsby-source-contentful
v7
We’re releasing a new major version of gatsby-source-contentful
as the support for gatsby-image
is dropped in favour fo the superior successor gatsby-plugin-image
. Read the Migrating from gatsby-image to gatsby-plugin-image guide to learn more. The PR #33528 implemented this change.
You can also use AVIF
images with Contentful now as the PR #33903 added support for this image format — use the new gatsby-plugin-image
to use it.
getServerData
improvements
A couple of improvements were made to the new Server-Side Rendering API inside Gatsby:
The response headers are now also applied during
gatsby develop
, via PR #33810You can (and should) use
process.env.*
environment variables insidegetServerData
, via PR #33690The status code returned by
getServerData
is respected now, via PR #33914. Please use this syntax (see reference guide):
Framework Version Support
You can find the support plans for the major versions of Gatsby on the newly created page Gatsby Framework Version Support.
Notable bugfixes & improvements
- A lot of internal dependency updates to each package, e.g. bumping
sharp
to0.29.2
. You can check theCHANGELOG.md
file in each package’s folder for the details gatsby
: Test files inside thesrc/api
(Gatsby Functions) directory are now excluded by default, via PR #33834gatsby-source-wordpress
:gatsby-core-utils
: Add retry on HTTP status codes tofetchRemoteFile
, via PR #33461- Content Sync:
- Content Sync is a Gatsby Cloud feature for improving the Preview experience for content authors. You can read more about it in the conceptual guide
gatsby-source-drupal
is prepared for Content Sync, via PR #33683- Update the Creating Pages documentation, via PR #33848
Contributors
A big Thank You to our community who contributed to this release 💜
- shreemaan-abhishek: chore(docs): fix issues in 0009-telemetry RFC PR #33829
- tonyhallett
- jstramel: searcParams missing from urls PR #33861
- axe312ger
- labifrancis: chore(gatsby-plugin-gatsby-google-analytics): Highlight the plugin we recommend PR #33901
- bytrangle: chore(docs): remove slug generation from MDX doc PR #33915
- Swarleys: feat(contentful): modifying schemes to add support for AVIF images PR #33903
- InfamousStarFox: Fixes incorrect link “programmatically creating pages from data” PR #33964
- SaloniThete: chore: Typo in BUG_REPORT PR #33971
- henryjw: chore(docs): Update client-only doc PR #33967