NavigaraNavigara
OrganizationsDistributionCompareResearch
NavigaraNavigara
OrganizationsDistributionCompareResearch
All developers

mofeiZ

Developer

mofeiZ

34200447+mofeiz@users.noreply.github.com

61 commits~15 files/commit

Performance

YoY:+36%
2026Previous year

Insights

Key patterns and highlights from this developer's activity.

Peak MonthMar'25698 performance
Growth Trend↓55%vs prior period
Avg Files/Commit15files per commit
Active Days28of 455 days
Top Reporeact61 commits

Effort Over Time

Breakdown of growth, maintenance, and fixes effort over time.

Bug Behavior

Beta

Bugs introduced vs. fixed over time.

Investment Quality

Beta

Reclassifies engineering effort based on bug attribution. Commits that introduced bugs are retrospectively counted as poor investments.

28%Productive TimeGrowth 36% + Fixes 64%
52%Maintenance Time
20%Wasted Time
How it works

Methodology

Investment Quality reclassifies engineering effort based on bug attribution data. Commits identified as buggy origins (those that introduced bugs later fixed by someone) have their grow and maintenance time moved into the Wasted Time category. Their waste (fix commits) remains counted as productive. All other commits retain their standard classification: grow is productive, maintenance is maintenance, and waste (fixes) is productive.

Relationship to Growth / Maintenance / Fixes

The standard model classifies commits as Growth, Maintenance, or Fixes. Investment Quality adds a quality lens: a commit that introduced a bug is retrospectively counted as a poor investment — the engineering time spent on it was wasted because it ultimately required additional fix work. Fix commits (Fixes in the standard model) are reframed as productive, because fixing bugs is valuable work.

Proposed API Endpoint

Currently computed client-side from commit and bug attribution data. Ideal server-side endpoint:

POST /v1/organizations/{orgId}/investment-quality
Content-Type: application/json

Request:
{
  "startTime": "2025-01-01T00:00:00Z",
  "endTime": "2025-12-31T23:59:59Z",
  "bucketSize": "BUCKET_SIZE_MONTH",
  "groupBy": ["repository_id" | "deliverer_email"]
}

Response:
{
  "productivePct": 74,
  "maintenancePct": 18,
  "wastedPct": 8,
  "buckets": [
    {
      "bucketStart": "2025-01-01T00:00:00Z",
      "productive": 4.2,
      "maintenance": 1.8,
      "wasted": 0.6
    }
  ]
}

Recent Activity

Latest analyzed commits from this developer.

HashMessageDateFilesEffort
2c2fd9dThis commit **fixes a security vulnerability** in the **playground's compiler configuration parsing** by replacing the insecure `new Function()` evaluation with **JSON5.parse** in `compiler/apps/playground/lib/compilation.ts`. This **refactoring** mitigates potential XSS risks and updates the `ConfigEditor.tsx` to support JSON5 syntax, including comments and trailing commas. The change introduces a dedicated `parseConfigOverrides` function and updates the default configuration format. Although some older playground URLs with custom configurations may be affected, the core functionality remains largely compatible, and the update is validated with **new unit and E2E tests**.Mar 307waste
eda778bThis commit delivers a **bug fix** for the **React Compiler**'s **memoization validation** logic, specifically resolving false positives within `ValidatePreserveExistingMemo`. It **refactors** the `recordDepsInValue` and `visitInstruction` functions in `compiler/packages/babel-plugin-react-compiler/src/Validation/ValidatePreservedManualMemoization.ts` to correctly identify and ignore dependency mismatches that arise when the compiler can memoize more precisely than the original `useMemo`, particularly with destructured values. This prevents the compiler from incorrectly flagging valid `useMemo` patterns where its optimized dependency analysis differs from the original `useMemo` dependencies. The change improves the **compiler's accuracy** and reduces developer friction by allowing more effective memoization without erroneous warnings.Sep 97maint
526dd34This commit provides a **bug fix** and **workaround** for an issue within the **Babel plugin for React Compiler** where Babel's compact mode produces invalid JavaScript for negative numeric literals. It modifies the codegen logic in `compiler/packages/babel-plugin-react-compiler/src/ReactiveScopes/CodegenReactiveFunction.ts` to **emit unary expressions** (e.g., `-(1)`) instead of direct negative numbers. This ensures that the generated code remains valid and parsable, even when processed by Babel in compact mode. New test fixtures and an update to enable compact mode in `compiler/packages/snap/src/compiler.ts` were added to validate this critical fix.Jun 24waste
f9ae0a4This commit introduces an **experimental configuration option**, `customOptOutDirectives`, within the **`babel-plugin-react-compiler`** to allow developers to specify their own custom directives for opting out of compiler features. This **new capability** enhances flexibility by enabling the compiler's directive parsing logic to respect user-defined opt-out rules, particularly for memoization. The change involves updating the **compiler's entrypoint options and program processing** to integrate this new setting, alongside **refactoring** of pragma parsing utilities in `TestUtils.ts` and the addition of **new test cases** to validate the functionality.May 275grow
0d07288This commit introduces a **feature enhancement** to the **React Compiler**, enabling it to correctly infer effect dependencies when **optional chaining** (`?.`) is used in component logic. It updates the core **dependency inference logic** within `InferEffectDependencies.ts` and adds new utility functions in `ScopeDependencyUtils.ts` to properly model optional chain expressions within the compiler's High-level Intermediate Representation (HIR). This ensures that expressions involving optional chains are accurately tracked as dependencies, preventing potential issues with incorrect memoization or re-renders. This **correctness improvement** enhances the reliability of the compiler's optimizations for components utilizing modern JavaScript syntax, with new and updated test fixtures validating the behavior. While a temporary solution, it significantly improves the compiler's understanding of reactive scopes.May 2212grow
abf9fd5This commit introduces a **`reactive` flag** to **scope dependencies** within the **React Compiler's High-Level Intermediate Representation (HIR)**. This **refactoring** modifies the core `ReactiveScopeDependency` type and updates various dependency collection and propagation passes, such as `CollectHoistablePropertyLoads` and `DeriveMinimalDependenciesHIR`, to track and propagate this new boolean property. The change provides more granular information about the reactivity of specific dependencies, laying crucial groundwork for future compiler optimizations. Specifically, it prepares the **compiler** for subsequent work that will rewrite scope dependencies into more efficient instructions, enabling more precise invalidation and performance improvements. While currently, some non-reactive properties of reactive objects might be broadly marked as reactive, this enhancement is a significant step towards more accurate dependency tracking.May 227maint
13f2004This commit performs a significant **refactoring** within the **React Compiler's Babel plugin** to **prepare the `HIRBuilder` for use by later compiler passes**. It centralizes contextual information by moving the `parentFunction` property from the `HIRBuilder` directly into the `Environment` object, which the builder now accesses. The `HIRBuilder`'s constructor was updated to use an options object for improved extensibility, and the `lower` function signatures in `BuildHIR.ts` were adjusted to align with these changes. This work enhances the modularity and reusability of the **HIR construction** process, enabling more sophisticated analysis and transformations in subsequent compiler stages.May 224maint
459a2c4This commit introduces an **experimental `dynamicGating` feature** to the **`babel-plugin-react-compiler`**, enabling directive-based conditional compilation. This **new capability** allows developers to control the application of compiler optimizations at runtime by using `use memo if(...)` directives, paired with a file-level `@dynamicGating` annotation. The compiler now generates code that can dynamically switch between an optimized and an original component version based on a runtime condition. This **feature** significantly enhances the **gating and memoization subsystems**, providing a mechanism for **phased rollouts and A/B testing** of compiler-optimized components. Extensive **test coverage** has been added to validate its behavior across various scenarios.May 2126maint
3820740This commit **fixes edge cases** in the **React Compiler's Babel plugin** related to `noEmit` configurations and module-level opt-outs. It **refactors the entrypoint program compilation logic** within `compiler/packages/babel-plugin-react-compiler/src/Entrypoint/Program.ts` to correctly respect these settings, ensuring that no unexpected runtime code is emitted when `noEmit` is active and properly handling modules that opt out of compilation. The changes introduce a new `hasModuleScopeOptOut` property in `ProgramContext` for tracking module-level opt-out status and improve error handling for unexpected compiled functions. This work is a **bug fix** that enhances the **compiler's reliability** and correctness for various project configurations.May 95waste
5069e18This commit **refactors** the **React Compiler's program traversal logic** to significantly improve readability and reduce complexity within the **Babel plugin's entrypoint**. It breaks down the lengthy `compileProgram` function into several smaller, more manageable helper functions, and centralizes compilation options, filename, code, and state management within the `ProgramContext`. This **internal restructuring** enhances the **maintainability** of the compiler's core logic by clarifying control flow and state handling, with **no functional changes** to the compilation output.May 99maint
38ef655This commit **standardizes the pragma format** within the **React Compiler's Babel plugin**, introducing a unified parsing logic for test-only, boolean, and JSON-valued configuration pragmas. This **refactoring** enhances consistency and maintainability of compiler configurations by centralizing pragma interpretation in `TestUtils.ts` and delegating parsing from `makePluginOptions`. The change impacts the **compiler's internal configuration handling** and necessitates widespread updates to **test fixtures and e2e snapshots** across the `babel-plugin-react-compiler` and `playground` modules to conform to the new pragma syntax.May 8182maint
b629a86This commit performs a **refactoring** within the **Babel plugin React compiler** to enhance modularity and reduce complexity. It **extracts test-specific configuration parsing logic**, including functions like `parseConfigPragmaForTests`, from the central `HIR/Environment.ts` module. This logic is now housed in a **new utility file**, `Utils/TestUtils.ts`, which also introduces related defaults and parsing functions like `parseConfigPragmaEnvironmentForTest`. The change **isolates testing concerns** from core environment configuration, requiring updates to import paths across the `compiler` and `snap` packages to reflect the relocation.May 86maint
fbe7bc2This commit introduces **new test fixtures** to the **React Compiler**'s Babel plugin, specifically designed to **reproduce and validate edge cases** in its behavior. It adds tests for the interaction between the `use memo` directive and the **`noEmit` directive**, ensuring the compiler correctly handles scenarios where output generation should be suppressed. Additionally, a test case verifies the compiler's outlining logic, confirming that outlining correctly **does not occur** in specific bailout situations when `panicThreshold(none)` is configured. These additions enhance the **compiler's robustness** by covering more complex scenarios and preventing regressions related to these critical directives and optimization behaviors.May 84maint
c129c24This commit introduces a **new test fixture** to reproduce a specific **error scenario** within the **`babel-plugin-react-compiler`**. It adds a JavaScript test case, `error.todo-fbt-param-nested-fbt.js`, demonstrating a problematic usage of **nested FBT calls** that currently causes **Babel build failures**. The accompanying `error.todo-fbt-param-nested-fbt.expect.md` documents the expected error output for this case. This **maintenance** work is crucial for improving the **compiler's robustness** by providing a clear reproduction for an issue that ideally should be detected and gracefully handled to prevent build failures.May 52maint
0c1575cThis commit introduces a **bug fix** to the **React Compiler**, specifically within the `PruneHoistedContexts` phase of `babel-plugin-react-compiler`. It implements a **bailout mechanism** to prevent incorrect compilation when **hoisted function declarations** are referenced before their definition within a **memo block**. This ensures the compiler avoids generating invalid JavaScript, though it currently results in "false positives" by bailing out on some safely rewritable scenarios. The change prioritizes correctness by preventing potential runtime errors caused by improper hoisting rewrites.May 56waste
9d795d3This commit introduces a **bug fix** to the **React Compiler's Intermediate Representation (HIR)**, specifically addressing incorrect handling of **hoisted context variables** that led to duplicate declarations. It **expands the `StoreContext` instruction** within the **HIR** to explicitly store the declaration kind (`Const`, `Let`, `Function`, or `Reassign`), providing more precise semantic information. This change allows the `PruneHoistedContexts` pass to correctly identify and eliminate redundant `DeclareContext` instructions, ensuring accurate representation of variable scopes and lifetimes. The **compiler's `BuildHIR` and `PruneHoistedContexts` passes**, along with **inference and codegen modules**, are updated to leverage this enhanced `StoreContext`, improving the correctness of the generated output for hoisted `let` and `const` declarations.Apr 3036waste
12f4cb8This commit **fixes a bug** in the **React Compiler's effects inference model**, specifically within the `babel-plugin-react-compiler` package. It addresses an edge case where **returned function expressions** were sometimes incorrectly inferred as 'frozen', even when they captured and mutated their outer context. The **bug fix** updates the `InferReferenceEffects.ts` module to ensure that returned values are only typed as 'frozen' if they are local and do not modify their surrounding scope. This **improves the correctness** of the compiler's analysis, preventing potential runtime issues from incorrect immutability assumptions for functions. New test fixtures are added to validate these specific scenarios.Apr 305waste
89e8875This commit introduces a **new fallback mechanism** within the **React Compiler's effect dependency inference** to handle scenarios where standard inference fails due to memoization bailouts or unexpected mutable ranges, such as writes to refs. This **enhancement improves the robustness and accuracy** of dependency detection by directly traversing the effect lambda, leveraging logic similar to `PropagateScopeDependencies` to collect loads, hoistable accesses, and property paths. The primary implementation is in `InferEffectDependencies.ts`, with supporting changes in `CollectHoistablePropertyLoads.ts` and `PropagateScopeDependenciesHIR.ts` to facilitate this new approach. This **new capability** ensures the compiler can correctly identify minimal dependencies in complex cases, thereby preventing incorrect re-renders or missed updates in applications.Apr 2512grow
2d0a5e3This commit **fixes a bug** in the **React Compiler's** `InferReactivePlaces` pass, which incorrectly identified stable-typed value blocks, such as ternary expressions involving `setState`, as non-reactive. It introduces a `StableSidemap` class and new utility functions in `compiler/packages/babel-plugin-react-compiler/src/HIR/HIR.ts` to accurately track and propagate stability. This **corrects the inference of reactive places** crucial for **inferred effect dependencies** and **inlined JSX**, ensuring these experimental compiler features behave as expected. The fix prevents incorrect optimizations or runtime issues by properly identifying **reactive refs** in complex control flow. New test fixtures are included to validate the corrected behavior for reactive refs within ternary expressions.Apr 255waste
0c28a09This commit implements a **maintenance fix** to resolve **non-deterministic builds** affecting the **`eslint-plugin-react-hooks`** package. The issue stemmed from inconsistent module wrapping by the Rollup commonjs plugin, particularly with cyclic dependencies involving `@babel/helper-string-parser` and `@babel/types`. To ensure build reliability and consistency, the Rollup configuration in `scripts/rollup/build.js` has been updated to explicitly set `strictRequires: true` for the commonjs plugin. This change forces all CommonJS modules to be wrapped, preventing build variations and guaranteeing more predictable CI outcomes, with a minor (~1.8%) increase in the `eslint-plugin-react-hooks` bundle size.Apr 251waste
2c2fd9dMar 30

This commit **fixes a security vulnerability** in the **playground's compiler configuration parsing** by replacing the insecure `new Function()` evaluation with **JSON5.parse** in `compiler/apps/playground/lib/compilation.ts`. This **refactoring** mitigates potential XSS risks and updates the `ConfigEditor.tsx` to support JSON5 syntax, including comments and trailing commas. The change introduces a dedicated `parseConfigOverrides` function and updates the default configuration format. Although some older playground URLs with custom configurations may be affected, the core functionality remains largely compatible, and the update is validated with **new unit and E2E tests**.

7 fileswaste
eda778bSep 9

This commit delivers a **bug fix** for the **React Compiler**'s **memoization validation** logic, specifically resolving false positives within `ValidatePreserveExistingMemo`. It **refactors** the `recordDepsInValue` and `visitInstruction` functions in `compiler/packages/babel-plugin-react-compiler/src/Validation/ValidatePreservedManualMemoization.ts` to correctly identify and ignore dependency mismatches that arise when the compiler can memoize more precisely than the original `useMemo`, particularly with destructured values. This prevents the compiler from incorrectly flagging valid `useMemo` patterns where its optimized dependency analysis differs from the original `useMemo` dependencies. The change improves the **compiler's accuracy** and reduces developer friction by allowing more effective memoization without erroneous warnings.

7 filesmaint
526dd34Jun 2

This commit provides a **bug fix** and **workaround** for an issue within the **Babel plugin for React Compiler** where Babel's compact mode produces invalid JavaScript for negative numeric literals. It modifies the codegen logic in `compiler/packages/babel-plugin-react-compiler/src/ReactiveScopes/CodegenReactiveFunction.ts` to **emit unary expressions** (e.g., `-(1)`) instead of direct negative numbers. This ensures that the generated code remains valid and parsable, even when processed by Babel in compact mode. New test fixtures and an update to enable compact mode in `compiler/packages/snap/src/compiler.ts` were added to validate this critical fix.

4 fileswaste
f9ae0a4May 27

This commit introduces an **experimental configuration option**, `customOptOutDirectives`, within the **`babel-plugin-react-compiler`** to allow developers to specify their own custom directives for opting out of compiler features. This **new capability** enhances flexibility by enabling the compiler's directive parsing logic to respect user-defined opt-out rules, particularly for memoization. The change involves updating the **compiler's entrypoint options and program processing** to integrate this new setting, alongside **refactoring** of pragma parsing utilities in `TestUtils.ts` and the addition of **new test cases** to validate the functionality.

5 filesgrow
0d07288May 22

This commit introduces a **feature enhancement** to the **React Compiler**, enabling it to correctly infer effect dependencies when **optional chaining** (`?.`) is used in component logic. It updates the core **dependency inference logic** within `InferEffectDependencies.ts` and adds new utility functions in `ScopeDependencyUtils.ts` to properly model optional chain expressions within the compiler's High-level Intermediate Representation (HIR). This ensures that expressions involving optional chains are accurately tracked as dependencies, preventing potential issues with incorrect memoization or re-renders. This **correctness improvement** enhances the reliability of the compiler's optimizations for components utilizing modern JavaScript syntax, with new and updated test fixtures validating the behavior. While a temporary solution, it significantly improves the compiler's understanding of reactive scopes.

12 filesgrow
abf9fd5May 22

This commit introduces a **`reactive` flag** to **scope dependencies** within the **React Compiler's High-Level Intermediate Representation (HIR)**. This **refactoring** modifies the core `ReactiveScopeDependency` type and updates various dependency collection and propagation passes, such as `CollectHoistablePropertyLoads` and `DeriveMinimalDependenciesHIR`, to track and propagate this new boolean property. The change provides more granular information about the reactivity of specific dependencies, laying crucial groundwork for future compiler optimizations. Specifically, it prepares the **compiler** for subsequent work that will rewrite scope dependencies into more efficient instructions, enabling more precise invalidation and performance improvements. While currently, some non-reactive properties of reactive objects might be broadly marked as reactive, this enhancement is a significant step towards more accurate dependency tracking.

7 filesmaint
13f2004May 22

This commit performs a significant **refactoring** within the **React Compiler's Babel plugin** to **prepare the `HIRBuilder` for use by later compiler passes**. It centralizes contextual information by moving the `parentFunction` property from the `HIRBuilder` directly into the `Environment` object, which the builder now accesses. The `HIRBuilder`'s constructor was updated to use an options object for improved extensibility, and the `lower` function signatures in `BuildHIR.ts` were adjusted to align with these changes. This work enhances the modularity and reusability of the **HIR construction** process, enabling more sophisticated analysis and transformations in subsequent compiler stages.

4 filesmaint
459a2c4May 21

This commit introduces an **experimental `dynamicGating` feature** to the **`babel-plugin-react-compiler`**, enabling directive-based conditional compilation. This **new capability** allows developers to control the application of compiler optimizations at runtime by using `use memo if(...)` directives, paired with a file-level `@dynamicGating` annotation. The compiler now generates code that can dynamically switch between an optimized and an original component version based on a runtime condition. This **feature** significantly enhances the **gating and memoization subsystems**, providing a mechanism for **phased rollouts and A/B testing** of compiler-optimized components. Extensive **test coverage** has been added to validate its behavior across various scenarios.

26 filesmaint
3820740May 9

This commit **fixes edge cases** in the **React Compiler's Babel plugin** related to `noEmit` configurations and module-level opt-outs. It **refactors the entrypoint program compilation logic** within `compiler/packages/babel-plugin-react-compiler/src/Entrypoint/Program.ts` to correctly respect these settings, ensuring that no unexpected runtime code is emitted when `noEmit` is active and properly handling modules that opt out of compilation. The changes introduce a new `hasModuleScopeOptOut` property in `ProgramContext` for tracking module-level opt-out status and improve error handling for unexpected compiled functions. This work is a **bug fix** that enhances the **compiler's reliability** and correctness for various project configurations.

5 fileswaste
5069e18May 9

This commit **refactors** the **React Compiler's program traversal logic** to significantly improve readability and reduce complexity within the **Babel plugin's entrypoint**. It breaks down the lengthy `compileProgram` function into several smaller, more manageable helper functions, and centralizes compilation options, filename, code, and state management within the `ProgramContext`. This **internal restructuring** enhances the **maintainability** of the compiler's core logic by clarifying control flow and state handling, with **no functional changes** to the compilation output.

9 filesmaint
38ef655May 8

This commit **standardizes the pragma format** within the **React Compiler's Babel plugin**, introducing a unified parsing logic for test-only, boolean, and JSON-valued configuration pragmas. This **refactoring** enhances consistency and maintainability of compiler configurations by centralizing pragma interpretation in `TestUtils.ts` and delegating parsing from `makePluginOptions`. The change impacts the **compiler's internal configuration handling** and necessitates widespread updates to **test fixtures and e2e snapshots** across the `babel-plugin-react-compiler` and `playground` modules to conform to the new pragma syntax.

182 filesmaint
b629a86May 8

This commit performs a **refactoring** within the **Babel plugin React compiler** to enhance modularity and reduce complexity. It **extracts test-specific configuration parsing logic**, including functions like `parseConfigPragmaForTests`, from the central `HIR/Environment.ts` module. This logic is now housed in a **new utility file**, `Utils/TestUtils.ts`, which also introduces related defaults and parsing functions like `parseConfigPragmaEnvironmentForTest`. The change **isolates testing concerns** from core environment configuration, requiring updates to import paths across the `compiler` and `snap` packages to reflect the relocation.

6 filesmaint
fbe7bc2May 8

This commit introduces **new test fixtures** to the **React Compiler**'s Babel plugin, specifically designed to **reproduce and validate edge cases** in its behavior. It adds tests for the interaction between the `use memo` directive and the **`noEmit` directive**, ensuring the compiler correctly handles scenarios where output generation should be suppressed. Additionally, a test case verifies the compiler's outlining logic, confirming that outlining correctly **does not occur** in specific bailout situations when `panicThreshold(none)` is configured. These additions enhance the **compiler's robustness** by covering more complex scenarios and preventing regressions related to these critical directives and optimization behaviors.

4 filesmaint
c129c24May 5

This commit introduces a **new test fixture** to reproduce a specific **error scenario** within the **`babel-plugin-react-compiler`**. It adds a JavaScript test case, `error.todo-fbt-param-nested-fbt.js`, demonstrating a problematic usage of **nested FBT calls** that currently causes **Babel build failures**. The accompanying `error.todo-fbt-param-nested-fbt.expect.md` documents the expected error output for this case. This **maintenance** work is crucial for improving the **compiler's robustness** by providing a clear reproduction for an issue that ideally should be detected and gracefully handled to prevent build failures.

2 filesmaint
0c1575cMay 5

This commit introduces a **bug fix** to the **React Compiler**, specifically within the `PruneHoistedContexts` phase of `babel-plugin-react-compiler`. It implements a **bailout mechanism** to prevent incorrect compilation when **hoisted function declarations** are referenced before their definition within a **memo block**. This ensures the compiler avoids generating invalid JavaScript, though it currently results in "false positives" by bailing out on some safely rewritable scenarios. The change prioritizes correctness by preventing potential runtime errors caused by improper hoisting rewrites.

6 fileswaste
9d795d3Apr 30

This commit introduces a **bug fix** to the **React Compiler's Intermediate Representation (HIR)**, specifically addressing incorrect handling of **hoisted context variables** that led to duplicate declarations. It **expands the `StoreContext` instruction** within the **HIR** to explicitly store the declaration kind (`Const`, `Let`, `Function`, or `Reassign`), providing more precise semantic information. This change allows the `PruneHoistedContexts` pass to correctly identify and eliminate redundant `DeclareContext` instructions, ensuring accurate representation of variable scopes and lifetimes. The **compiler's `BuildHIR` and `PruneHoistedContexts` passes**, along with **inference and codegen modules**, are updated to leverage this enhanced `StoreContext`, improving the correctness of the generated output for hoisted `let` and `const` declarations.

36 fileswaste
12f4cb8Apr 30

This commit **fixes a bug** in the **React Compiler's effects inference model**, specifically within the `babel-plugin-react-compiler` package. It addresses an edge case where **returned function expressions** were sometimes incorrectly inferred as 'frozen', even when they captured and mutated their outer context. The **bug fix** updates the `InferReferenceEffects.ts` module to ensure that returned values are only typed as 'frozen' if they are local and do not modify their surrounding scope. This **improves the correctness** of the compiler's analysis, preventing potential runtime issues from incorrect immutability assumptions for functions. New test fixtures are added to validate these specific scenarios.

5 fileswaste
89e8875Apr 25

This commit introduces a **new fallback mechanism** within the **React Compiler's effect dependency inference** to handle scenarios where standard inference fails due to memoization bailouts or unexpected mutable ranges, such as writes to refs. This **enhancement improves the robustness and accuracy** of dependency detection by directly traversing the effect lambda, leveraging logic similar to `PropagateScopeDependencies` to collect loads, hoistable accesses, and property paths. The primary implementation is in `InferEffectDependencies.ts`, with supporting changes in `CollectHoistablePropertyLoads.ts` and `PropagateScopeDependenciesHIR.ts` to facilitate this new approach. This **new capability** ensures the compiler can correctly identify minimal dependencies in complex cases, thereby preventing incorrect re-renders or missed updates in applications.

12 filesgrow
2d0a5e3Apr 25

This commit **fixes a bug** in the **React Compiler's** `InferReactivePlaces` pass, which incorrectly identified stable-typed value blocks, such as ternary expressions involving `setState`, as non-reactive. It introduces a `StableSidemap` class and new utility functions in `compiler/packages/babel-plugin-react-compiler/src/HIR/HIR.ts` to accurately track and propagate stability. This **corrects the inference of reactive places** crucial for **inferred effect dependencies** and **inlined JSX**, ensuring these experimental compiler features behave as expected. The fix prevents incorrect optimizations or runtime issues by properly identifying **reactive refs** in complex control flow. New test fixtures are included to validate the corrected behavior for reactive refs within ternary expressions.

5 fileswaste
0c28a09Apr 25

This commit implements a **maintenance fix** to resolve **non-deterministic builds** affecting the **`eslint-plugin-react-hooks`** package. The issue stemmed from inconsistent module wrapping by the Rollup commonjs plugin, particularly with cyclic dependencies involving `@babel/helper-string-parser` and `@babel/types`. To ensure build reliability and consistency, the Rollup configuration in `scripts/rollup/build.js` has been updated to explicitly set `strictRequires: true` for the commonjs plugin. This change forces all CommonJS modules to be wrapped, preventing build variations and guaranteeing more predictable CI outcomes, with a minor (~1.8%) increase in the `eslint-plugin-react-hooks` bundle size.

1 fileswaste

Work Patterns

Beta

Commit activity distribution by hour and day of week. Shows when this developer is most active.

Collaboration

Beta

Developers who frequently work on the same files and symbols. Higher score means stronger code collaboration.

NavigaraNavigara
OrganizationsDistributionCompareResearch