react.dev icon indicating copy to clipboard operation
react.dev copied to clipboard

[Typo]: Code typo in React compiler reference link

Open CottonCandyZ opened this issue 1 year ago • 0 comments
trafficstars

Summary

React Compiler Doc first Note references a link to the Working Group Discussion

There is a code typo in that discussion (comment inline):

  const $ = _c(3);
  if ($[0] !== todos || $[1] !== tab) {
    t1 = filterTodos(todos, tab);
    $[0] = todos;
    $[1] = tab;
    $[2] = t2; // should be t1?
  } else {
    t1 = $[2];
  }

  const visibleTodos = t1

Page

https://github.com/reactwg/react-compiler/discussions/6

Details

I cannot find any way to directly report this typo in discussion, so I am reporting here.

The problem is simple:

$[2] = t2; should be $[2] = t1;

CottonCandyZ avatar May 23 '24 06:05 CottonCandyZ