The new React compiler is now in experimental version, you can check if your current codebase is compatible by testing your project with health check command
Testing your project with npx react-compiler-healthcheck command
Before trying the new react 19 feature, React Compiler, it is recommended to check compatibility first.
- Open one of your React project directories.
- Start a new terminal and execute this npx command
npx react-compiler-healthcheck
After executing this command it will ask you to install experimental health check package, say yes.
After that it will scan you codebase and give you the information about :
- How many components can optimized
- Usage of StrictMode
- List of incompatible libraries
You should see output like this one below