website/blog/releases/3.7/index.mdx
We are happy to announce Docusaurus 3.7.
Docusaurus is now compatible with React 19.
Upgrading should be easy. Our release process respects Semantic Versioning. Minor versions do not include any breaking changes.
In #10763, we added support for React 19, and the Docusaurus website is running on React 19 already.
From now on, all newly initialized sites will run on React 19 by default, and React 19 will be the minimum required version Docusaurus v4.
However, React 18 remains supported, and existing Docusaurus sites can either choose to stay on React 18, or upgrade their dependencies to React 19:
{
"name": "my-docusaurus-site",
"dependencies": {
- "react": "^18.0.0",
- "react-dom": "^18.0.0"
+ "react": "^19.0.0",
+ "react-dom": "^19.0.0"
}
}
:::warning
There's no urge to upgrade your site immediately.
React 19 is a bit heavier than React 18. Since we support both versions, we don't leverage yet the new features that are exclusive to React 19.
However, upgrading to React 19 prepares your site for Docusaurus v4, that will drop support for React 18.
Here are good reasons to upgrade your site before Docusaurus v4:
:::
Along the way, we fixed all the remaining hydration errors reported by React 19, some of them produced by our aggressive HTML minifier settings.
Docusaurus has built-in support for SVGR, allowing you to seamlessly import and use SVG files as React components:
import DocusaurusSvg from './docusaurus.svg';
<DocusaurusSvg />;
This built-in support has been the source of various bug reports due to the inability to customize the SVGR Options, in particular the SVG Optimizer options.
In #10677, we extracted a new @docusaurus/plugin-svgr that you can now configure according to your needs. It is included by default in our classic preset:
export default {
presets: [
[
'classic',
{
svgr: {
svgrConfig: {
// Your SVGR options ...
svgoConfig: {
// Your SVGO options ...
// Use "svgoConfig: undefined" to use a svgo.config.js file
},
},
},
},
],
],
};
Other notable changes include:
frontMatter.sidebar_label@docusaurus/remark-plugin-npm2yarn now supports Bun conversions.algoliasearch v5.Check the 3.7.0 changelog entry for an exhaustive list of changes.