Sunny-117/js-challenges

实现简易版的useState

Sunny-117 opened this issue · 1 comments

  1. 基于fiber
  2. 不限

const useState = (v) => { const setV = (_v) => { v = _v }; render(); return [v, setV] }