this repo has no description
1import spacepack from "@moonlight-mod/wp/spacepack_spacepack";
2
3const mod = spacepack.findByCode("connectStores:")[0].exports;
4
5const useStateFromStores = spacepack.findFunctionByStrings(
6 mod,
7 '"useStateFromStores"'
8)!;
9
10module.exports = {
11 BatchedStoreListener: spacepack.findFunctionByStrings(
12 mod,
13 " tried to load a non-existent store."
14 ),
15 Dispatcher: spacepack.findFunctionByStrings(mod, "_dispatchWithDevtools("),
16 Store: spacepack.findFunctionByStrings(mod, "registerActionHandlers("),
17 default: mod.ZP,
18 statesWillNeverBeEqual: spacepack.findFunctionByStrings(mod, "return!1"),
19 useStateFromStores,
20 useStateFromStoresArray: spacepack.findFunctionByStrings(
21 mod,
22 new RegExp(`return ${useStateFromStores.name}\\(.+?\\.[^Z]\\)`)
23 ),
24 useStateFromStoresObject: spacepack.findFunctionByStrings(
25 mod,
26 new RegExp(`return ${useStateFromStores.name}\\(.+?\\.Z\\)`)
27 )
28};