0.0.5 • Published 2 years ago

reox v0.0.5

Weekly downloads
-
License
MIT
Repository
-
Last release
2 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

2 years ago

0.0.4

2 years ago

0.0.1

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.0

2 years ago