Files
react/compiler
Mike Vitousek 28fe581bac [compiler] Option for preserving calls to useMemo/useCallback
Summary: This adds a compiler option to not drop existing manual memoization and leaving useMemo/useCallback in the generated source. Why do we need this, given that we also have options to validate or ensure that existing memoization is preserved? It's because later diffs on this stack are designed to alter the behavior of the memoization that the compiler emits, in order to detect rules of react violations and debug issues. We don't want to change the behavior of user-level memoization, however, since doing so would be altering the semantics of the user's program in an unacceptable way.

ghstack-source-id: 89dccdec9ccb4306b16e849e9fa2170bb5dd021f
Pull Request resolved: https://github.com/facebook/react/pull/29654
2024-05-31 14:02:13 -07:00
..
2024-05-29 11:46:27 +09:00
2024-05-29 11:46:27 +09:00
2024-04-16 14:41:13 +01:00
2024-05-29 11:46:27 +09:00
2024-05-29 11:46:27 +09:00
2024-05-29 11:46:27 +09:00
2024-05-06 14:53:47 -07:00
2024-05-29 11:46:27 +09:00

React Compiler

React Compiler is a compiler that optimizes React applications, ensuring that only the minimal parts of components and hooks will re-render when state changes. The compiler also validates that components and hooks follow the Rules of React.

More information about the design and architecture of the compiler are covered in the Design Goals.

More information about developing the compiler itself is covered in the Development Guide.