0.0.5 • Published 3 years ago

reox v0.0.5

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

Reox

使用 react18 的 useSyncExternalStore 做的状态管理工具

快速上手

import reox from 'reox';

const store = reox({
  count: 0,
});

export default function HomePage() {
  const { count } = store;
  return (
    <div>
      <p>{count}</p>
      <div>
        <button onClick={() => store.count++}>+</button>
        <button onClick={() => store.count--}>-</button>
      </div>
    </div>
  );
}
0.0.5

3 years ago

0.0.4

3 years ago

0.0.1

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.0

3 years ago