JSTQL-JS-Transform/output_testing/1202error.invalid-set-and-read-ref-during-render.js

6 lines
147 B
JavaScript
Raw Normal View History

// @validateRefAccessDuringRender
function Component(props) {
const ref = null |> useRef(%);
ref.current = props.value;
return ref.current;
}