dillon1000/react
Commit
Browse files Detect unknown hooks on React namespace
Handles an edge-case from earlier in the stack. When looking up a property on a shape, if the property is defined we return it. But if it isn't defined, and the property name is a hook, we treat it like a default custom hook.
Changed paths4 files
First-parent comparisoncompiler/packages/babel-plugin-react-forget/src/HIR/Environment.ts ModifiedM compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/drop-methodcall-usememo.expect.md ModifiedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/error.conditional-hook-unknown-hook-react-namespace.expect.md AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/error.conditional-hook-unknown-hook-react-namespace.js AddedPatch
Files changed
Rendering syntax-highlighted changes…