dillon1000/react
Commit
Browse files [babel] Don't use source location for hoisting check
Instead of using the source location to check for hoisting, just stop checking for a given component after we reach it's declaration. By definition all references to it before are (potential) hoisting errors. Note that there could be false positives but that's ok.
Changed paths4 files
First-parent comparisoncompiler/packages/babel-plugin-react-forget/src/Entrypoint/Program.ts ModifiedD compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/component-syntax-ref-gating.flow.expect.md DeletedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/error.component-syntax-ref-gating.flow.expect.md AddedR compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/component-syntax-ref-gating.flow.js →compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/error.component-syntax-ref-gating.flow.js RenamedPatch
Files changed
Rendering syntax-highlighted changes…