dillon1000/react
Commit
Browse files Repro of for loop with context variable iterator variable
`let` bindings of context variables are lowered to a DeclareContext + StoreContext, which breaks codegen for `for` loops which expect that all statements of the init block will lower to variable declarations. The two instructions produce a variable declaration and a reassignment.
Changed paths2 files
First-parent comparisoncompiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/error.todo-for-loop-with-context-variable-iterator.expect.md AddedA compiler/packages/babel-plugin-react-forget/src/__tests__/fixtures/compiler/error.todo-for-loop-with-context-variable-iterator.js AddedPatch
Files changed
Rendering syntax-highlighted changes…