Initial commit — Pokemon Doors Randomiser

This commit is contained in:
2026-06-03 20:25:09 +09:30
commit 4737c2c905
3029 changed files with 632320 additions and 0 deletions
+1
View File
@@ -0,0 +1 @@
export declare function useShallow<S, U>(selector: (state: S) => U): (state: S) => U;
+12
View File
@@ -0,0 +1,12 @@
import React from 'react';
import { shallow } from 'zustand/vanilla/shallow';
function useShallow(selector) {
const prev = React.useRef(void 0);
return (state) => {
const next = selector(state);
return shallow(prev.current, next) ? prev.current : prev.current = next;
};
}
export { useShallow };