dillon1000/react

Commit

noAlias support for CallExpr incl hooks

Adds `noAlias` support for CallExpression, including hooks. Note that we treat 
hook arguments as escaping by default — ie we assume that they don't just flow 
into the hook return value, but are just outright escape points equivalent to a 
return. A `noAlias` annotation on a hook definition disables both: this will 
allow us to avoid memoizing the `graphql` tag arguments to `useFragment`, for 
example.
Browse files
Changed paths6 files
First-parent comparison
M compiler/packages/babel-plugin-react-forget/src/HIR/Environment.ts ModifiedM compiler/packages/babel-plugin-react-forget/src/ReactiveScopes/PruneNonEscapingScopes.ts ModifiedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/hook-noAlias.expect.md AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/hook-noAlias.js AddedM compiler/packages/fixture-test-utils/src/compiler-utils.ts ModifiedM compiler/packages/sprout/src/shared-runtime.ts Modified
Patch

Files changed

Rendering syntax-highlighted changes…