@tamagui/use-store 2.7.7 → 3.0.0-beta.643.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/comparators.cjs +27 -30
- package/dist/cjs/comparators.native.cjs +45 -0
- package/dist/cjs/comparators.native.js +31 -34
- package/dist/cjs/comparators.native.js.map +1 -1
- package/dist/cjs/configureUseStore.cjs +17 -18
- package/dist/cjs/configureUseStore.native.cjs +33 -0
- package/dist/cjs/configureUseStore.native.js +17 -17
- package/dist/cjs/configureUseStore.native.js.map +1 -1
- package/dist/cjs/constants.cjs +19 -20
- package/dist/cjs/constants.native.cjs +34 -0
- package/dist/cjs/constants.native.js +19 -19
- package/dist/cjs/constants.native.js.map +1 -1
- package/dist/cjs/decorators.cjs +19 -22
- package/dist/cjs/decorators.native.cjs +32 -0
- package/dist/cjs/decorators.native.js +19 -21
- package/dist/cjs/decorators.native.js.map +1 -1
- package/dist/cjs/helpers.cjs +39 -40
- package/dist/cjs/helpers.native.cjs +68 -0
- package/dist/cjs/helpers.native.js +42 -43
- package/dist/cjs/helpers.native.js.map +1 -1
- package/dist/cjs/index.cjs +22 -23
- package/dist/cjs/index.native.cjs +62 -0
- package/dist/cjs/index.native.js +35 -36
- package/dist/cjs/index.native.js.map +1 -1
- package/dist/cjs/interfaces.cjs +10 -11
- package/dist/cjs/interfaces.native.cjs +19 -0
- package/dist/cjs/interfaces.native.js +10 -10
- package/dist/cjs/interfaces.native.js.map +1 -1
- package/dist/cjs/observe.cjs +132 -138
- package/dist/cjs/observe.native.cjs +221 -0
- package/dist/cjs/observe.native.js +192 -203
- package/dist/cjs/observe.native.js.map +1 -1
- package/dist/cjs/useStore.cjs +366 -403
- package/dist/cjs/useStore.native.cjs +557 -0
- package/dist/cjs/useStore.native.js +487 -536
- package/dist/cjs/useStore.native.js.map +1 -1
- package/dist/cjs/useStoreDebug.cjs +39 -45
- package/dist/cjs/useStoreDebug.native.cjs +64 -0
- package/dist/cjs/useStoreDebug.native.js +43 -48
- package/dist/cjs/useStoreDebug.native.js.map +1 -1
- package/dist/esm/comparators.mjs +13 -12
- package/dist/esm/comparators.mjs.map +1 -1
- package/dist/esm/comparators.native.js +17 -17
- package/dist/esm/comparators.native.js.map +1 -1
- package/dist/esm/configureUseStore.mjs +2 -1
- package/dist/esm/configureUseStore.mjs.map +1 -1
- package/dist/esm/configureUseStore.native.js +2 -1
- package/dist/esm/configureUseStore.native.js.map +1 -1
- package/dist/esm/constants.mjs +4 -3
- package/dist/esm/constants.mjs.map +1 -1
- package/dist/esm/constants.native.js +4 -3
- package/dist/esm/constants.native.js.map +1 -1
- package/dist/esm/decorators.mjs +5 -4
- package/dist/esm/decorators.mjs.map +1 -1
- package/dist/esm/decorators.native.js +5 -4
- package/dist/esm/decorators.native.js.map +1 -1
- package/dist/esm/helpers.mjs +20 -18
- package/dist/esm/helpers.mjs.map +1 -1
- package/dist/esm/helpers.native.js +23 -22
- package/dist/esm/helpers.native.js.map +1 -1
- package/dist/esm/index.js +18 -11
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/index.mjs +18 -11
- package/dist/esm/index.mjs.map +1 -1
- package/dist/esm/index.native.js +30 -24
- package/dist/esm/index.native.js.map +1 -1
- package/dist/esm/interfaces.mjs +0 -2
- package/dist/esm/interfaces.native.js +0 -2
- package/dist/esm/observe.mjs +115 -113
- package/dist/esm/observe.mjs.map +1 -1
- package/dist/esm/observe.native.js +175 -179
- package/dist/esm/observe.native.js.map +1 -1
- package/dist/esm/useStore.mjs +336 -363
- package/dist/esm/useStore.mjs.map +1 -1
- package/dist/esm/useStore.native.js +457 -497
- package/dist/esm/useStore.native.js.map +1 -1
- package/dist/esm/useStoreDebug.mjs +20 -18
- package/dist/esm/useStoreDebug.mjs.map +1 -1
- package/dist/esm/useStoreDebug.native.js +23 -21
- package/dist/esm/useStoreDebug.native.js.map +1 -1
- package/package.json +3 -3
- package/dist/esm/interfaces.mjs.map +0 -1
- package/dist/esm/interfaces.native.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["isNodeMode","mod","__esModule","__defProp","target","value","enumerable","__toCommonJS","__copyProps","useStore_exports","__export","allStores","createStore","createUseStore","createUseStoreSelector","getOrCreateStore","getStore","getStoreInfo","onCreateStore","setIsInReaction","trackStoresAccess","useGlobalStore","useGlobalStoreSelector","useStore","useStoreDebug","useStoreSelector","module","exports","import_react","__toESM","require","import_comparators","import_configureUseStore","import_constants","import_helpers","import_useStoreDebug","_instanceof","left","right","Symbol","hasInstance","idFn","_","StoreKlass","props","options","arguments","length","defaultOptions","useStoreFromInfo","getOrCreateStoreInfo","selector","debug","_getOrCreateStoreInfo","store","instance","UNWRAP_PROXY","uid","getStoreUid","constructor","info","cache","get","Error","storeAccessTrackers","Set","cb","add","delete","_getStoreInfo","refuseCreation","onCreateListeners","propsKeyCalculated","_store_mount","avoidCache","has","name","storeInstance","getters","actions","stateKeys","descriptors","getStoreDescriptors","key","descriptor","keyComparators","listeners","storeInfo","disableTracking","gettersState","getCache","Map","depsToGetter","curGetKeys","isGetting","trackers","version","subscribe","onChanged","triggerUpdate","Number","MAX_SAFE_INTEGER","_iteratorNormalCompletion","_didIteratorError","_iteratorError","_iterator","iterator","_step","next","done","err","return","createProxiedStore","process","env","NODE_ENV","mount","call","result","set","forEach","_globalThis","_Store","globalThis","emptyObj","selectKeys","obj","keys","res","isInReaction","curInternal","val","userSelector","internal","default","useRef","component","useCurrentComponent","current","tracked","last","lastKeys","shouldPrintDebug","getSnapshot","useCallback","curInternal2","isTracking","size","nextKeys","join","snap","isUnchanged","isEqualSubsetShallow","console","storeState","Object","state","useSyncExternalStore","Proxy","curVal","Reflect","keyString","setters","logStack","_loop","key2","actionFn","isGetFn","startsWith","wrappedActions","useStoreAction","_len","args","Array","_key","apply","proxiedStore","shouldDebug2","Promise","then","finishAction","hashCode2","str","hash","i","charCodeAt","strColor2","ogAction","thisArg","isDebugging","LOG_LEVEL","configureOpts","logLevel","curSetters","isTopLevelLogger","logs","id","counter","error","constr","color","simpleArgs","map","simpleStr","padStart","param","key3","item","groupEnd","head","rest","groupCollapsed","trace","_iteratorNormalCompletion1","_didIteratorError1","_iteratorError1","_iterator1","_step1","name1","log","_iteratorNormalCompletion2","_didIteratorError2","_iteratorError2","_iterator2","_step2","clear","_storeInfo_debug","DebugStores","didSet","isTriggering","passThroughKeys","UNWRAP_STORE_INFO","isSubGetter","gk","receiver","cur","clearGetterCache","getShouldDebug","waitForEventLoop","setKey","parentGetters"],"sources":["../../src/useStore.tsx"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAAA,UAAA,KAAAC,GAAA,KAAAA,GAAA,CAAAC,UAAA,GAAAC,SAAA,CAAAC,MAAA;EAAAC,KAAA,EAAAJ,GAAA;EAAAK,UAAA;AAAA,KAAAF,MAAA,EAAAH,GAAA;AAAA,IAAAM,YAAA,GAAAN,GAAA,IAAAO,WAAA,CAAAL,SAAA;EAAAE,KAAA;AAAA,IAAAJ,GAAA;AAAA,IAAAQ,gBAAA;AAAAC,QAAA,CAAAD,gBAAA;EAAAE,SAAA,EAAAA,CAAA,KAAAA,SAAA;EAAAC,WAAA,EAAAA,CAAA,KAAAA,WAAA;EAAAC,cAAA,EAAAA,CAAA,KAAAA,cAAA;EAAAC,sBAAA,EAAAA,CAAA,KAAAA,sBAAA;EAAAC,gBAAA,EAAAA,CAAA,KAAAA,gBAAA;EAAAC,QAAA,EAAAA,CAAA,KAAAA,QAAA;EAAAC,YAAA,EAAAA,CAAA,KAAAA,YAAA;EAAAC,aAAA,EAAAA,CAAA,KAAAA,aAAA;EAAAC,eAAA,EAAAA,CAAA,KAAAA,eAAA;EAAAC,iBAAA,EAAAA,CAAA,KAAAA,iBAAA;EAAAC,cAAA,EAAAA,CAAA,KAAkBA,cAAA;EAElBC,sBAAA,EAAqCA,CAAA,KAAAA,sBAAA;EACrCC,QAAA,EAAAA,CAAA,KAAAA,QAAA;EACAC,aAAA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AAM;MACJ;QACA,KAAAR,yBAAU,IAAAG,SAAA,CAAAM,MAAA,UAAAN,SAAA,CAAAM,MAAA;MACV,UAAW;QACX,IAAAR,iBAAU,QAAAC,cAAA;MACV;IACA;EACF;EASA,OAAAwE,YAAS;AACP;AACA,IAAA8D,gBAAiB,IAAA7H,OAAU,CAAAC,GAAA,CAAAC,QAAA,YAAAjD,EAAA;EAC3B,OAAAA,EAAQ;AAAa;AACkD,IACvEmI,OAAA;AACF,IAAAiC,eAAA","ignoreList":[]}
|
|
1
|
+
{"version":3,"file":"useStore.native.js","names":[],"sources":["cjs/useStore.native.js"],"sourcesContent":["\"use strict\";\nvar __create = Object.create;\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __getProtoOf = Object.getPrototypeOf;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n\tfor (var name in all) __defProp(target, name, {\n\t\tget: all[name],\n\t\tenumerable: true\n\t});\n};\nvar __copyProps = (to, from, except, desc) => {\n\tif (from && typeof from === \"object\" || typeof from === \"function\") {\n\t\tfor (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {\n\t\t\tget: () => from[key],\n\t\t\tenumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable\n\t\t});\n\t}\n\treturn to;\n};\nvar __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(\n\t// If the importer is in node compatibility mode or this is not an ESM\n\t// file that has been converted to a CommonJS file using a Babel-\n\t// compatible transform (i.e. \"__esModule\" has not been set), then set\n\t// \"default\" to the CommonJS \"module.exports\" for node compatibility.\n\tisNodeMode || !mod || !mod.__esModule ? __defProp(target, \"default\", {\n\t\tvalue: mod,\n\t\tenumerable: true\n\t}) : target,\n\tmod\n));\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\nvar useStore_exports = {};\n__export(useStore_exports, {\n\tallStores: () => allStores,\n\tcreateStore: () => createStore,\n\tcreateUseStore: () => createUseStore,\n\tcreateUseStoreSelector: () => createUseStoreSelector,\n\tgetOrCreateStore: () => getOrCreateStore,\n\tgetStore: () => getStore,\n\tgetStoreInfo: () => getStoreInfo,\n\tonCreateStore: () => onCreateStore,\n\tsetIsInReaction: () => setIsInReaction,\n\ttrackStoresAccess: () => trackStoresAccess,\n\tuseGlobalStore: () => useGlobalStore,\n\tuseGlobalStoreSelector: () => useGlobalStoreSelector,\n\tuseStore: () => useStore,\n\tuseStoreDebug: () => useStoreDebug,\n\tuseStoreSelector: () => useStoreSelector\n});\nmodule.exports = __toCommonJS(useStore_exports);\nvar import_react = __toESM(require(\"react\"), 1);\nvar import_comparators = require(\"./comparators\");\nvar import_configureUseStore = require(\"./configureUseStore\");\nvar import_constants = require(\"./constants\");\nvar import_helpers = require(\"./helpers\");\nvar import_useStoreDebug = require(\"./useStoreDebug\");\nfunction _instanceof(left, right) {\n\tif (right != null && typeof Symbol !== \"undefined\" && right[Symbol.hasInstance]) return !!right[Symbol.hasInstance](left);\n\telse return left instanceof right;\n}\nvar idFn = function(_) {\n\treturn _;\n};\nfunction useStore(StoreKlass, props) {\n\tvar options = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : import_constants.defaultOptions;\n\treturn useStoreFromInfo(getOrCreateStoreInfo(StoreKlass, props, options), options.selector, options);\n}\nfunction useStoreDebug(StoreKlass, props) {\n\treturn useStore(StoreKlass, props, { debug: true });\n}\nfunction createStore(StoreKlass, props, options) {\n\tvar _getOrCreateStoreInfo;\n\treturn (_getOrCreateStoreInfo = getOrCreateStoreInfo(StoreKlass, props, options)) === null || _getOrCreateStoreInfo === void 0 ? void 0 : _getOrCreateStoreInfo.store;\n}\nfunction useGlobalStore(instance, debug) {\n\tvar store = instance[import_constants.UNWRAP_PROXY];\n\tvar uid = (0, import_helpers.getStoreUid)(store.constructor, store.props);\n\tvar info = import_helpers.cache.get(uid);\n\tif (!info) throw new Error(`This store not created using createStore()`);\n\treturn useStoreFromInfo(info, void 0, { debug });\n}\nfunction useGlobalStoreSelector(instance, selector, debug) {\n\tvar store = instance[import_constants.UNWRAP_PROXY];\n\tvar uid = (0, import_helpers.getStoreUid)(store.constructor, store.props);\n\tvar info = import_helpers.cache.get(uid);\n\tif (!info) throw new Error(`This store not created using createStore()`);\n\treturn useStoreFromInfo(info, selector, { debug });\n}\nfunction createUseStore(StoreKlass) {\n\treturn function(props, options) {\n\t\treturn useStore(StoreKlass, props, options);\n\t};\n}\nfunction createUseStoreSelector(StoreKlass, selector) {\n\treturn function(props) {\n\t\treturn useStore(StoreKlass, props, { selector });\n\t};\n}\nfunction useStoreSelector(StoreKlass, selector, props) {\n\treturn useStore(StoreKlass, props, { selector });\n}\nvar storeAccessTrackers = /* @__PURE__ */ new Set();\nfunction trackStoresAccess(cb) {\n\tstoreAccessTrackers.add(cb);\n\treturn function() {\n\t\tstoreAccessTrackers.delete(cb);\n\t};\n}\nfunction getStore(StoreKlass, props) {\n\tvar _getStoreInfo;\n\treturn (_getStoreInfo = getStoreInfo(StoreKlass, props)) === null || _getStoreInfo === void 0 ? void 0 : _getStoreInfo.store;\n}\nfunction getOrCreateStore(StoreKlass, props) {\n\tvar _getOrCreateStoreInfo;\n\treturn (_getOrCreateStoreInfo = getOrCreateStoreInfo(StoreKlass, props, { refuseCreation: false })) === null || _getOrCreateStoreInfo === void 0 ? void 0 : _getOrCreateStoreInfo.store;\n}\nfunction getStoreInfo(StoreKlass, props) {\n\treturn getOrCreateStoreInfo(StoreKlass, props, { refuseCreation: true });\n}\nvar onCreateListeners = /* @__PURE__ */ new Set();\nfunction onCreateStore(cb) {\n\tonCreateListeners.add(cb);\n\treturn function() {\n\t\tonCreateListeners.delete(cb);\n\t};\n}\nfunction getOrCreateStoreInfo(StoreKlass, props, options, propsKeyCalculated) {\n\tvar _store_mount;\n\tif (!StoreKlass) return null;\n\tvar uid = (0, import_helpers.getStoreUid)(StoreKlass, propsKeyCalculated !== null && propsKeyCalculated !== void 0 ? propsKeyCalculated : props);\n\tif (!(options === null || options === void 0 ? void 0 : options.avoidCache) && import_helpers.cache.has(uid)) return import_helpers.cache.get(uid);\n\tif (options === null || options === void 0 ? void 0 : options.refuseCreation) throw new Error(`No store exists (${StoreKlass.name}) with props: ${props}`);\n\tvar storeInstance = new StoreKlass(props);\n\tstoreInstance.props = props;\n\tvar getters = {};\n\tvar actions = {};\n\tvar stateKeys = /* @__PURE__ */ new Set();\n\tvar descriptors = (0, import_helpers.getStoreDescriptors)(storeInstance);\n\tfor (var key in descriptors) {\n\t\tvar descriptor = descriptors[key];\n\t\tif (typeof descriptor.value === \"function\") actions[key] = descriptor.value;\n\t\telse if (typeof descriptor.get === \"function\") getters[key] = descriptor.get;\n\t\telse if (key !== \"props\" && key[0] !== \"_\") stateKeys.add(key);\n\t}\n\tvar keyComparators = storeInstance[\"_comparators\"];\n\tvar listeners = /* @__PURE__ */ new Set();\n\tvar storeInfo = {\n\t\tuid,\n\t\tkeyComparators,\n\t\tstoreInstance,\n\t\tgetters,\n\t\tstateKeys,\n\t\tprops,\n\t\tactions,\n\t\tdebug: options === null || options === void 0 ? void 0 : options.debug,\n\t\tdisableTracking: false,\n\t\tgettersState: {\n\t\t\tgetCache: /* @__PURE__ */ new Map(),\n\t\t\tdepsToGetter: /* @__PURE__ */ new Map(),\n\t\t\tcurGetKeys: /* @__PURE__ */ new Set(),\n\t\t\tisGetting: false\n\t\t},\n\t\tlisteners,\n\t\ttrackers: /* @__PURE__ */ new Set(),\n\t\tversion: 0,\n\t\tsubscribe: function(onChanged) {\n\t\t\tlisteners.add(onChanged);\n\t\t\treturn function() {\n\t\t\t\tlisteners.delete(onChanged);\n\t\t\t};\n\t\t},\n\t\ttriggerUpdate: function() {\n\t\t\tstoreInfo.version = (storeInfo.version + 1) % Number.MAX_SAFE_INTEGER;\n\t\t\tvar _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = void 0;\n\t\t\ttry {\n\t\t\t\tfor (var _iterator = listeners[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {\n\t\t\t\t\tvar cb = _step.value;\n\t\t\t\t\tcb();\n\t\t\t\t}\n\t\t\t} catch (err) {\n\t\t\t\t_didIteratorError = true;\n\t\t\t\t_iteratorError = err;\n\t\t\t} finally {\n\t\t\t\ttry {\n\t\t\t\t\tif (!_iteratorNormalCompletion && _iterator.return != null) _iterator.return();\n\t\t\t\t} finally {\n\t\t\t\t\tif (_didIteratorError) throw _iteratorError;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t};\n\tvar store = createProxiedStore(\n\t\t// we assign store right after and proxiedStore never accesses it until later on\n\t\tstoreInfo\n\t);\n\tif (process.env.NODE_ENV === \"development\") allStores[StoreKlass.name + uid] = store;\n\t(_store_mount = store.mount) === null || _store_mount === void 0 || _store_mount.call(store);\n\tstoreInfo.store = store;\n\tvar result = storeInfo;\n\timport_helpers.cache.set(uid, result);\n\tonCreateListeners.forEach(function(cb) {\n\t\treturn cb(result);\n\t});\n\treturn result;\n}\nvar allStores = {};\nif (process.env.NODE_ENV === \"development\") {\n\tvar _globalThis, _Store;\n\t(_globalThis = globalThis)[_Store = \"Store\"] || (_globalThis[_Store] = allStores);\n}\nvar emptyObj = {};\nvar selectKeys = function(obj, keys) {\n\tif (!keys.length) return emptyObj;\n\tvar res = {};\n\tvar _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = void 0;\n\ttry {\n\t\tfor (var _iterator = keys[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {\n\t\t\tvar key = _step.value;\n\t\t\tres[key] = obj[key];\n\t\t}\n\t} catch (err) {\n\t\t_didIteratorError = true;\n\t\t_iteratorError = err;\n\t} finally {\n\t\ttry {\n\t\t\tif (!_iteratorNormalCompletion && _iterator.return != null) _iterator.return();\n\t\t} finally {\n\t\t\tif (_didIteratorError) throw _iteratorError;\n\t\t}\n\t}\n\treturn res;\n};\nvar isInReaction = false;\nvar setIsInReaction = function(val) {\n\tisInReaction = val;\n};\nfunction useStoreFromInfo(info, userSelector, options) {\n\tvar store = info === null || info === void 0 ? void 0 : info.store;\n\tvar internal = import_react.default.useRef(void 0);\n\tvar component = (0, import_useStoreDebug.useCurrentComponent)();\n\tif (!internal.current) internal.current = {\n\t\tcomponent,\n\t\ttracked: /* @__PURE__ */ new Set(),\n\t\tlast: null,\n\t\tlastKeys: null\n\t};\n\tvar curInternal = internal.current;\n\tvar shouldPrintDebug = options === null || options === void 0 ? void 0 : options.debug;\n\tvar getSnapshot = import_react.default.useCallback(function() {\n\t\tif (!info || !store) return;\n\t\tvar curInternal2 = internal.current;\n\t\tvar isTracking = curInternal2.tracked.size;\n\t\tvar keys = [...!isTracking ? info.stateKeys : curInternal2.tracked];\n\t\tvar nextKeys = `${info.version}${keys.join(\"\")}${userSelector || \"\"}`;\n\t\tvar lastKeys = curInternal2.lastKeys;\n\t\tif (nextKeys === curInternal2.lastKeys) return curInternal2.last;\n\t\tcurInternal2.lastKeys = nextKeys;\n\t\tvar snap;\n\t\tinfo.disableTracking = true;\n\t\tvar last = curInternal2.last;\n\t\tif (userSelector) snap = userSelector(store);\n\t\telse snap = selectKeys(store, keys);\n\t\tinfo.disableTracking = false;\n\t\tvar isUnchanged = !userSelector && !isTracking && last || typeof last !== \"undefined\" && (0, import_comparators.isEqualSubsetShallow)(last, snap, { keyComparators: info.keyComparators });\n\t\tif (shouldPrintDebug) console.info(\"🌑 getSnapshot\", {\n\t\t\tstoreState: selectKeys(store, Object.keys(store)),\n\t\t\tuserSelector,\n\t\t\tinfo,\n\t\t\tisUnchanged,\n\t\t\tcomponent,\n\t\t\tkeys,\n\t\t\tlast,\n\t\t\tsnap,\n\t\t\tcurInternal: curInternal2,\n\t\t\tnextKeys,\n\t\t\tlastKeys\n\t\t});\n\t\tif (isUnchanged) return last;\n\t\tcurInternal2.last = snap;\n\t\treturn snap;\n\t}, [store]);\n\tvar state = import_react.default.useSyncExternalStore((info === null || info === void 0 ? void 0 : info.subscribe) || idFn, getSnapshot, getSnapshot);\n\tif (!info || !store || !state) return state;\n\tif (userSelector) return state;\n\treturn new Proxy(store, { get(target, key) {\n\t\tvar curVal = Reflect.get(target, key);\n\t\tif (isInReaction) return curVal;\n\t\tvar keyString = key;\n\t\tif (info.stateKeys.has(keyString) || keyString in info.getters) {\n\t\t\tif (shouldPrintDebug) console.info(\"👀 tracking\", keyString);\n\t\t\tcurInternal.tracked.add(keyString);\n\t\t}\n\t\tif (Reflect.has(state, key)) return Reflect.get(state, key);\n\t\treturn curVal;\n\t} });\n}\nvar setters = /* @__PURE__ */ new Set();\nvar logStack = /* @__PURE__ */ new Set();\nfunction createProxiedStore(storeInfo) {\n\tvar _loop = function(key2) {\n\t\tif (key2 === \"subscribe\") return \"continue\";\n\t\tvar actionFn = actions[key2];\n\t\tvar isGetFn = key2.startsWith(\"get\");\n\t\twrappedActions[key2] = function useStoreAction() {\n\t\t\tfor (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key];\n\t\t\tvar res;\n\t\t\tif (isGetFn || gettersState.isGetting) return Reflect.apply(actionFn, proxiedStore, args);\n\t\t\tif (process.env.NODE_ENV === \"development\" && shouldDebug2) console.info(\"(debug) startAction\", key2);\n\t\t\tres = Reflect.apply(actionFn, proxiedStore, args);\n\t\t\tif (_instanceof(res, Promise)) return res.then(finishAction);\n\t\t\tfinishAction();\n\t\t\treturn res;\n\t\t};\n\t\tif (process.env.NODE_ENV === \"development\") {\n\t\t\tlet hashCode2 = function(str) {\n\t\t\t\tvar hash = 0;\n\t\t\t\tfor (var i = 0; i < str.length; i++) hash = str.charCodeAt(i) + ((hash << 5) - hash);\n\t\t\t\treturn hash;\n\t\t\t}, strColor2 = function(str) {\n\t\t\t\treturn `hsl(${hashCode2(str) % 360}, 90%, 40%)`;\n\t\t\t};\n\t\t\tif (!key2.startsWith(\"get\") && !key2.startsWith(\"_\") && key2 !== \"subscribe\") {\n\t\t\t\tvar ogAction = wrappedActions[key2];\n\t\t\t\twrappedActions[key2] = new Proxy(ogAction, { apply(target, thisArg, args) {\n\t\t\t\t\tvar isDebugging = shouldDebug2 || storeInfo.debug;\n\t\t\t\t\tif (!(process.env.LOG_LEVEL !== \"0\" && (isDebugging || import_configureUseStore.configureOpts.logLevel !== \"error\"))) return Reflect.apply(target, thisArg, args);\n\t\t\t\t\tsetters = /* @__PURE__ */ new Set();\n\t\t\t\t\tvar curSetters = setters;\n\t\t\t\t\tvar isTopLevelLogger = logStack.size == 0;\n\t\t\t\t\tvar logs = /* @__PURE__ */ new Set();\n\t\t\t\t\tlogStack.add(logs);\n\t\t\t\t\tvar res;\n\t\t\t\t\tvar id = counter++;\n\t\t\t\t\ttry {\n\t\t\t\t\t\tres = Reflect.apply(target, thisArg, args);\n\t\t\t\t\t} catch (err) {\n\t\t\t\t\t\tconsole.error(\"Error\", err);\n\t\t\t\t\t\tthrow err;\n\t\t\t\t\t} finally {\n\t\t\t\t\t\tlogStack.add(\"end\");\n\t\t\t\t\t\tvar name = constr.name;\n\t\t\t\t\t\tvar color = strColor2(name);\n\t\t\t\t\t\tvar simpleArgs = args.map(import_helpers.simpleStr);\n\t\t\t\t\t\tlogs.add([\n\t\t\t\t\t\t\t`%c \\u{1F311} ${id} ${name.padStart(isTopLevelLogger ? 8 : 4)}%c.${key2}(${simpleArgs.join(\", \")})${isTopLevelLogger && logStack.size > 1 ? ` (+${logStack.size - 1})` : \"\"}`,\n\t\t\t\t\t\t\t`color: ${color};`,\n\t\t\t\t\t\t\t\"color: black;\"\n\t\t\t\t\t\t]);\n\t\t\t\t\t\tif (curSetters.size) curSetters.forEach(function(param) {\n\t\t\t\t\t\t\tvar { key: key3, value } = param;\n\t\t\t\t\t\t\tif (typeof value === \"string\" || typeof value === \"number\" || typeof value === \"boolean\") logs.add([` SET ${key3} ${value}`, value]);\n\t\t\t\t\t\t\telse logs.add([` SET ${key3}`, value]);\n\t\t\t\t\t\t});\n\t\t\t\t\t\tif (isTopLevelLogger) {\n\t\t\t\t\t\t\tvar error = null;\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\tvar _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = void 0;\n\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\tfor (var _iterator = logStack[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {\n\t\t\t\t\t\t\t\t\t\tvar item = _step.value;\n\t\t\t\t\t\t\t\t\t\tif (item === \"end\") {\n\t\t\t\t\t\t\t\t\t\t\tconsole.groupEnd();\n\t\t\t\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tvar [head, ...rest] = item;\n\t\t\t\t\t\t\t\t\t\tif (head) {\n\t\t\t\t\t\t\t\t\t\t\tconsole.groupCollapsed(...head);\n\t\t\t\t\t\t\t\t\t\t\tconsole.groupCollapsed(\"...\");\n\t\t\t\t\t\t\t\t\t\t\tconsole.info(\"args\", args);\n\t\t\t\t\t\t\t\t\t\t\tconsole.info(\"response\", res);\n\t\t\t\t\t\t\t\t\t\t\tconsole.groupCollapsed(\"trace\");\n\t\t\t\t\t\t\t\t\t\t\tconsole.trace();\n\t\t\t\t\t\t\t\t\t\t\tconsole.groupEnd();\n\t\t\t\t\t\t\t\t\t\t\tconsole.groupEnd();\n\t\t\t\t\t\t\t\t\t\t\tvar _iteratorNormalCompletion1 = true, _didIteratorError1 = false, _iteratorError1 = void 0;\n\t\t\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t\t\tfor (var _iterator1 = rest[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = true) {\n\t\t\t\t\t\t\t\t\t\t\t\t\tvar [name1, ...log] = _step1.value;\n\t\t\t\t\t\t\t\t\t\t\t\t\tconsole.groupCollapsed(name1);\n\t\t\t\t\t\t\t\t\t\t\t\t\tconsole.info(...log);\n\t\t\t\t\t\t\t\t\t\t\t\t\tconsole.groupEnd();\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t} catch (err) {\n\t\t\t\t\t\t\t\t\t\t\t\t_didIteratorError1 = true;\n\t\t\t\t\t\t\t\t\t\t\t\t_iteratorError1 = err;\n\t\t\t\t\t\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (!_iteratorNormalCompletion1 && _iterator1.return != null) _iterator1.return();\n\t\t\t\t\t\t\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t\t\t\t\t\t\tif (_didIteratorError1) throw _iteratorError1;\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t} else console.info(\"Weird log\", head, ...rest);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t} catch (err) {\n\t\t\t\t\t\t\t\t\t_didIteratorError = true;\n\t\t\t\t\t\t\t\t\t_iteratorError = err;\n\t\t\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\tif (!_iteratorNormalCompletion && _iterator.return != null) _iterator.return();\n\t\t\t\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t\t\t\tif (_didIteratorError) throw _iteratorError;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} catch (err) {\n\t\t\t\t\t\t\t\terror = err;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tvar _iteratorNormalCompletion2 = true, _didIteratorError2 = false, _iteratorError2 = void 0;\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\tfor (var _iterator2 = logStack[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) {\n\t\t\t\t\t\t\t\t\t_step2.value;\n\t\t\t\t\t\t\t\t\tconsole.groupEnd();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} catch (err) {\n\t\t\t\t\t\t\t\t_didIteratorError2 = true;\n\t\t\t\t\t\t\t\t_iteratorError2 = err;\n\t\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\tif (!_iteratorNormalCompletion2 && _iterator2.return != null) _iterator2.return();\n\t\t\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\t\t\tif (_didIteratorError2) throw _iteratorError2;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (error) console.error(`error loggin`, error);\n\t\t\t\t\t\t\tlogStack.clear();\n\t\t\t\t\t\t}\n\t\t\t\t\t\treturn res;\n\t\t\t\t\t}\n\t\t\t\t} });\n\t\t\t}\n\t\t}\n\t};\n\tvar { actions, storeInstance, getters, gettersState } = storeInfo;\n\tvar { getCache, curGetKeys, depsToGetter } = gettersState;\n\tvar constr = storeInstance.constructor;\n\tvar _storeInfo_debug;\n\tvar shouldDebug2 = (_storeInfo_debug = storeInfo.debug) !== null && _storeInfo_debug !== void 0 ? _storeInfo_debug : import_useStoreDebug.DebugStores.has(constr);\n\tvar didSet = false;\n\tvar wrappedActions = {};\n\tfor (var key in actions) _loop(key);\n\tvar finishAction = function(val) {\n\t\tif (process.env.NODE_ENV === \"development\" && shouldDebug2) console.info(\"(debug) finishAction\", { didSet });\n\t\tif (didSet) {\n\t\t\tstoreInfo.triggerUpdate();\n\t\t\tdidSet = false;\n\t\t}\n\t\treturn val;\n\t};\n\tvar isTriggering = false;\n\tvar proxiedStore = new Proxy(storeInstance, {\n\t\tget(_, key2) {\n\t\t\tif (key2 in wrappedActions) return wrappedActions[key2];\n\t\t\tif (key2 in passThroughKeys) return Reflect.get(storeInstance, key2);\n\t\t\tif (key2 === import_constants.UNWRAP_PROXY) return storeInstance;\n\t\t\tif (key2 === import_helpers.UNWRAP_STORE_INFO) return storeInfo;\n\t\t\tif (storeAccessTrackers.size) storeAccessTrackers.forEach(function(cb) {\n\t\t\t\treturn cb(storeInfo);\n\t\t\t});\n\t\t\tif (typeof key2 !== \"string\") return Reflect.get(storeInstance, key2);\n\t\t\tif (!storeInfo.disableTracking) {\n\t\t\t\tif (gettersState.isGetting) gettersState.curGetKeys.add(key2);\n\t\t\t}\n\t\t\tif (key2 in getters) {\n\t\t\t\tif (getCache.has(key2)) return getCache.get(key2);\n\t\t\t\tcurGetKeys.clear();\n\t\t\t\tvar isSubGetter = gettersState.isGetting;\n\t\t\t\tgettersState.isGetting = true;\n\t\t\t\tvar res = getters[key2].call(proxiedStore);\n\t\t\t\tif (!isSubGetter) gettersState.isGetting = false;\n\t\t\t\tvar _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = void 0;\n\t\t\t\ttry {\n\t\t\t\t\tfor (var _iterator = curGetKeys[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {\n\t\t\t\t\t\tvar gk = _step.value;\n\t\t\t\t\t\tif (!depsToGetter.has(gk)) depsToGetter.set(gk, /* @__PURE__ */ new Set());\n\t\t\t\t\t\tdepsToGetter.get(gk).add(key2);\n\t\t\t\t\t}\n\t\t\t\t} catch (err) {\n\t\t\t\t\t_didIteratorError = true;\n\t\t\t\t\t_iteratorError = err;\n\t\t\t\t} finally {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tif (!_iteratorNormalCompletion && _iterator.return != null) _iterator.return();\n\t\t\t\t\t} finally {\n\t\t\t\t\t\tif (_didIteratorError) throw _iteratorError;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tgetCache.set(key2, res);\n\t\t\t\treturn res;\n\t\t\t}\n\t\t\treturn Reflect.get(storeInstance, key2);\n\t\t},\n\t\tset(target, key2, value, receiver) {\n\t\t\tvar cur = Reflect.get(target, key2);\n\t\t\tvar res = Reflect.set(target, key2, value, receiver);\n\t\t\tif (res && cur !== value) {\n\t\t\t\tif (typeof key2 === \"string\") {\n\t\t\t\t\tclearGetterCache(key2);\n\t\t\t\t\tif (shouldDebug2) {\n\t\t\t\t\t\tsetters.add({\n\t\t\t\t\t\t\tkey: key2,\n\t\t\t\t\t\t\tvalue\n\t\t\t\t\t\t});\n\t\t\t\t\t\tif (getShouldDebug(storeInfo)) console.info(\"(debug) SET\", res, key2, value);\n\t\t\t\t\t}\n\t\t\t\t\tif (process.env.NODE_ENV === \"development\" && shouldDebug2) console.info(\"SET...\", {\n\t\t\t\t\t\tkey: key2,\n\t\t\t\t\t\tvalue\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tif (!isTriggering) {\n\t\t\t\t\tisTriggering = true;\n\t\t\t\t\twaitForEventLoop(function() {\n\t\t\t\t\t\tstoreInfo.triggerUpdate();\n\t\t\t\t\t\tisTriggering = false;\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn res;\n\t\t}\n\t});\n\tfunction clearGetterCache(setKey) {\n\t\tvar parentGetters = depsToGetter.get(setKey);\n\t\tgetCache.delete(setKey);\n\t\tif (!parentGetters) return;\n\t\tvar _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = void 0;\n\t\ttry {\n\t\t\tfor (var _iterator = parentGetters[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {\n\t\t\t\tvar gk = _step.value;\n\t\t\t\tgetCache.delete(gk);\n\t\t\t\tif (depsToGetter.has(gk)) clearGetterCache(gk);\n\t\t\t}\n\t\t} catch (err) {\n\t\t\t_didIteratorError = true;\n\t\t\t_iteratorError = err;\n\t\t} finally {\n\t\t\ttry {\n\t\t\t\tif (!_iteratorNormalCompletion && _iterator.return != null) _iterator.return();\n\t\t\t} finally {\n\t\t\t\tif (_didIteratorError) throw _iteratorError;\n\t\t\t}\n\t\t}\n\t}\n\treturn proxiedStore;\n}\nvar waitForEventLoop = (process.env.NODE_ENV, function(cb) {\n\treturn cb();\n});\nvar counter = 0;\nvar passThroughKeys = {\n\tsubscribe: true,\n\t_version: true,\n\t_trackers: true,\n\t$$typeof: true,\n\t_listeners: true,\n\t_enableTracking: true\n};\nfunction getShouldDebug(storeInfo) {\n\tvar info = { storeInstance: storeInfo.store };\n\treturn [...storeInfo.trackers].some(function(tracker) {\n\t\treturn tracker.component && (0, import_useStoreDebug.shouldDebug)(tracker.component, info);\n\t});\n}\n//# sourceMappingURL=useStore.js.map\n"],"mappings":";;;;AACA,IAAI,WAAW,OAAO;AACtB,IAAI,YAAY,OAAO;AACvB,IAAI,mBAAmB,OAAO;AAC9B,IAAI,oBAAoB,OAAO;AAC/B,IAAI,eAAe,OAAO;AAC1B,IAAI,eAAe,OAAO,UAAU;AACpC,IAAI,YAAY,QAAQ,QAAQ;CAC/B,KAAK,IAAI,QAAQ,KAAK,UAAU,QAAQ,MAAM;EAC7C,KAAK,IAAI;EACT,YAAY;CACb,CAAC;AACF;AACA,IAAI,eAAe,IAAI,MAAM,QAAQ,SAAS;CAC7C,IAAI,QAAQ,OAAO,SAAS,YAAY,OAAO,SAAS,YAAY;EACnE,KAAK,IAAI,OAAO,kBAAkB,IAAI,GAAG,IAAI,CAAC,aAAa,KAAK,IAAI,GAAG,KAAK,QAAQ,QAAQ,UAAU,IAAI,KAAK;GAC9G,WAAW,KAAK;GAChB,YAAY,EAAE,OAAO,iBAAiB,MAAM,GAAG,MAAM,KAAK;EAC3D,CAAC;CACF;CACA,OAAO;AACR;AACA,IAAI,WAAW,KAAK,YAAY,YAAY,SAAS,OAAO,OAAO,SAAS,aAAa,GAAG,CAAC,IAAI,CAAC,GAAG,YAKpG,cAAc,CAAC,OAAO,CAAC,IAAI,aAAa,UAAU,QAAQ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O,EAAE,eAAe,UAAU,MAAM;CAC5C,OAAO,CAAC,GAAG,UAAU,QAAQ,EAAE,KAAK,SAAS,SAAS;EACrD,OAAO,QAAQ,cAAc,GAAG,qBAAqB,aAAa,QAAQ,WAAW,IAAI;CAC1F,CAAC;AACF"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
|
|
1
2
|
var __create = Object.create;
|
|
2
3
|
var __defProp = Object.defineProperty;
|
|
3
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -5,63 +6,56 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
|
5
6
|
var __getProtoOf = Object.getPrototypeOf;
|
|
6
7
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
8
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
for (var name in all) __defProp(target, name, {
|
|
10
|
+
get: all[name],
|
|
11
|
+
enumerable: true
|
|
12
|
+
});
|
|
12
13
|
};
|
|
13
14
|
var __copyProps = (to, from, except, desc) => {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
15
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
16
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
17
|
+
get: () => from[key],
|
|
18
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
return to;
|
|
21
22
|
};
|
|
22
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
26
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
27
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
28
|
-
value: mod,
|
|
29
|
-
enumerable: true
|
|
23
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
24
|
+
value: mod,
|
|
25
|
+
enumerable: true
|
|
30
26
|
}) : target, mod));
|
|
31
|
-
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
32
|
-
value: true
|
|
33
|
-
}), mod);
|
|
27
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
34
28
|
var useStoreDebug_exports = {};
|
|
35
29
|
__export(useStoreDebug_exports, {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
30
|
+
DebugComponents: () => DebugComponents,
|
|
31
|
+
DebugStores: () => DebugStores,
|
|
32
|
+
shouldDebug: () => shouldDebug,
|
|
33
|
+
useCurrentComponent: () => useCurrentComponent,
|
|
34
|
+
useDebugStoreComponent: () => useDebugStoreComponent
|
|
41
35
|
});
|
|
42
36
|
module.exports = __toCommonJS(useStoreDebug_exports);
|
|
43
37
|
var import_react = __toESM(require("react"), 1);
|
|
44
38
|
const useCurrentComponent = () => {
|
|
45
|
-
|
|
39
|
+
return {};
|
|
46
40
|
};
|
|
47
41
|
function useDebugStoreComponent(StoreCons) {
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
42
|
+
const cmp = useCurrentComponent();
|
|
43
|
+
DebugStores.add(StoreCons);
|
|
44
|
+
if (!DebugComponents.has(cmp)) {
|
|
45
|
+
DebugComponents.set(cmp, /* @__PURE__ */ new Set());
|
|
46
|
+
}
|
|
47
|
+
const stores = DebugComponents.get(cmp);
|
|
48
|
+
stores.add(StoreCons);
|
|
49
|
+
import_react.default.useLayoutEffect(() => {
|
|
50
|
+
return () => {
|
|
51
|
+
DebugStores.delete(StoreCons);
|
|
52
|
+
stores.delete(StoreCons);
|
|
53
|
+
};
|
|
54
|
+
}, []);
|
|
61
55
|
}
|
|
62
56
|
const shouldDebug = (component, info) => {
|
|
63
|
-
|
|
64
|
-
|
|
57
|
+
const StoreCons = info.storeInstance?.constructor;
|
|
58
|
+
return DebugComponents.get(component)?.has(StoreCons);
|
|
65
59
|
};
|
|
66
|
-
const DebugComponents = /* @__PURE__ */new Map();
|
|
67
|
-
const DebugStores = /* @__PURE__ */new Set();
|
|
60
|
+
const DebugComponents = /* @__PURE__ */ new Map();
|
|
61
|
+
const DebugStores = /* @__PURE__ */ new Set();
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
var __create = Object.create;
|
|
5
|
+
var __defProp = Object.defineProperty;
|
|
6
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
8
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
9
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
10
|
+
var __export = (target, all) => {
|
|
11
|
+
for (var name in all) __defProp(target, name, {
|
|
12
|
+
get: all[name],
|
|
13
|
+
enumerable: true
|
|
14
|
+
});
|
|
15
|
+
};
|
|
16
|
+
var __copyProps = (to, from, except, desc) => {
|
|
17
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
18
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
19
|
+
get: () => from[key],
|
|
20
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
return to;
|
|
24
|
+
};
|
|
25
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
26
|
+
value: mod,
|
|
27
|
+
enumerable: true
|
|
28
|
+
}) : target, mod));
|
|
29
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
30
|
+
var useStoreDebug_exports = {};
|
|
31
|
+
__export(useStoreDebug_exports, {
|
|
32
|
+
DebugComponents: () => DebugComponents,
|
|
33
|
+
DebugStores: () => DebugStores,
|
|
34
|
+
shouldDebug: () => shouldDebug,
|
|
35
|
+
useCurrentComponent: () => useCurrentComponent,
|
|
36
|
+
useDebugStoreComponent: () => useDebugStoreComponent
|
|
37
|
+
});
|
|
38
|
+
module.exports = __toCommonJS(useStoreDebug_exports);
|
|
39
|
+
var import_react = __toESM(require("react"), 1);
|
|
40
|
+
var useCurrentComponent = function() {
|
|
41
|
+
return {};
|
|
42
|
+
};
|
|
43
|
+
function useDebugStoreComponent(StoreCons) {
|
|
44
|
+
var cmp = useCurrentComponent();
|
|
45
|
+
DebugStores.add(StoreCons);
|
|
46
|
+
if (!DebugComponents.has(cmp)) {
|
|
47
|
+
DebugComponents.set(cmp, /* @__PURE__ */ new Set());
|
|
48
|
+
}
|
|
49
|
+
var stores = DebugComponents.get(cmp);
|
|
50
|
+
stores.add(StoreCons);
|
|
51
|
+
import_react.default.useLayoutEffect(function() {
|
|
52
|
+
return function() {
|
|
53
|
+
DebugStores.delete(StoreCons);
|
|
54
|
+
stores.delete(StoreCons);
|
|
55
|
+
};
|
|
56
|
+
}, []);
|
|
57
|
+
}
|
|
58
|
+
var shouldDebug = function(component, info) {
|
|
59
|
+
var _info_storeInstance, _DebugComponents_get;
|
|
60
|
+
var StoreCons = (_info_storeInstance = info.storeInstance) === null || _info_storeInstance === void 0 ? void 0 : _info_storeInstance.constructor;
|
|
61
|
+
return (_DebugComponents_get = DebugComponents.get(component)) === null || _DebugComponents_get === void 0 ? void 0 : _DebugComponents_get.has(StoreCons);
|
|
62
|
+
};
|
|
63
|
+
var DebugComponents = /* @__PURE__ */ new Map();
|
|
64
|
+
var DebugStores = /* @__PURE__ */ new Set();
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
|
|
3
4
|
var __create = Object.create;
|
|
4
5
|
var __defProp = Object.defineProperty;
|
|
5
6
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -7,65 +8,59 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
|
7
8
|
var __getProtoOf = Object.getPrototypeOf;
|
|
8
9
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
10
|
var __export = (target, all) => {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
11
|
+
for (var name in all) __defProp(target, name, {
|
|
12
|
+
get: all[name],
|
|
13
|
+
enumerable: true
|
|
14
|
+
});
|
|
14
15
|
};
|
|
15
16
|
var __copyProps = (to, from, except, desc) => {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
17
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
18
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
19
|
+
get: () => from[key],
|
|
20
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
return to;
|
|
23
24
|
};
|
|
24
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
28
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
29
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
30
|
-
value: mod,
|
|
31
|
-
enumerable: true
|
|
25
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
26
|
+
value: mod,
|
|
27
|
+
enumerable: true
|
|
32
28
|
}) : target, mod));
|
|
33
|
-
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
34
|
-
value: true
|
|
35
|
-
}), mod);
|
|
29
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
36
30
|
var useStoreDebug_exports = {};
|
|
37
31
|
__export(useStoreDebug_exports, {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
32
|
+
DebugComponents: () => DebugComponents,
|
|
33
|
+
DebugStores: () => DebugStores,
|
|
34
|
+
shouldDebug: () => shouldDebug,
|
|
35
|
+
useCurrentComponent: () => useCurrentComponent,
|
|
36
|
+
useDebugStoreComponent: () => useDebugStoreComponent
|
|
43
37
|
});
|
|
44
38
|
module.exports = __toCommonJS(useStoreDebug_exports);
|
|
45
39
|
var import_react = __toESM(require("react"), 1);
|
|
46
|
-
var useCurrentComponent = function
|
|
47
|
-
|
|
40
|
+
var useCurrentComponent = function() {
|
|
41
|
+
return {};
|
|
48
42
|
};
|
|
49
43
|
function useDebugStoreComponent(StoreCons) {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
44
|
+
var cmp = useCurrentComponent();
|
|
45
|
+
DebugStores.add(StoreCons);
|
|
46
|
+
if (!DebugComponents.has(cmp)) {
|
|
47
|
+
DebugComponents.set(cmp, /* @__PURE__ */ new Set());
|
|
48
|
+
}
|
|
49
|
+
var stores = DebugComponents.get(cmp);
|
|
50
|
+
stores.add(StoreCons);
|
|
51
|
+
import_react.default.useLayoutEffect(function() {
|
|
52
|
+
return function() {
|
|
53
|
+
DebugStores.delete(StoreCons);
|
|
54
|
+
stores.delete(StoreCons);
|
|
55
|
+
};
|
|
56
|
+
}, []);
|
|
63
57
|
}
|
|
64
|
-
var shouldDebug = function
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
58
|
+
var shouldDebug = function(component, info) {
|
|
59
|
+
var _info_storeInstance, _DebugComponents_get;
|
|
60
|
+
var StoreCons = (_info_storeInstance = info.storeInstance) === null || _info_storeInstance === void 0 ? void 0 : _info_storeInstance.constructor;
|
|
61
|
+
return (_DebugComponents_get = DebugComponents.get(component)) === null || _DebugComponents_get === void 0 ? void 0 : _DebugComponents_get.has(StoreCons);
|
|
68
62
|
};
|
|
69
|
-
var DebugComponents = /* @__PURE__ */new Map();
|
|
70
|
-
var DebugStores = /* @__PURE__ */new Set();
|
|
63
|
+
var DebugComponents = /* @__PURE__ */ new Map();
|
|
64
|
+
var DebugStores = /* @__PURE__ */ new Set();
|
|
65
|
+
|
|
71
66
|
//# sourceMappingURL=useStoreDebug.native.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"useStoreDebug.native.js","names":[],"sources":["cjs/useStoreDebug.native.js"],"sourcesContent":["\"use strict\";\nvar __create = Object.create;\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __getProtoOf = Object.getPrototypeOf;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n for (var name in all)\n __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n if (from && typeof from === \"object\" || typeof from === \"function\") {\n for (let key of __getOwnPropNames(from))\n if (!__hasOwnProp.call(to, key) && key !== except)\n __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n }\n return to;\n};\nvar __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(\n // If the importer is in node compatibility mode or this is not an ESM\n // file that has been converted to a CommonJS file using a Babel-\n // compatible transform (i.e. \"__esModule\" has not been set), then set\n // \"default\" to the CommonJS \"module.exports\" for node compatibility.\n isNodeMode || !mod || !mod.__esModule ? __defProp(target, \"default\", { value: mod, enumerable: true }) : target,\n mod\n));\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\nvar useStoreDebug_exports = {};\n__export(useStoreDebug_exports, {\n DebugComponents: () => DebugComponents,\n DebugStores: () => DebugStores,\n shouldDebug: () => shouldDebug,\n useCurrentComponent: () => useCurrentComponent,\n useDebugStoreComponent: () => useDebugStoreComponent\n});\nmodule.exports = __toCommonJS(useStoreDebug_exports);\nvar import_react = __toESM(require(\"react\"), 1);\nvar useCurrentComponent = function() {\n return {};\n};\nfunction useDebugStoreComponent(StoreCons) {\n var cmp = useCurrentComponent();\n DebugStores.add(StoreCons);\n if (!DebugComponents.has(cmp)) {\n DebugComponents.set(cmp, /* @__PURE__ */ new Set());\n }\n var stores = DebugComponents.get(cmp);\n stores.add(StoreCons);\n import_react.default.useLayoutEffect(function() {\n return function() {\n DebugStores.delete(StoreCons);\n stores.delete(StoreCons);\n };\n }, []);\n}\nvar shouldDebug = function(component, info) {\n var _info_storeInstance, _DebugComponents_get;\n var StoreCons = (_info_storeInstance = info.storeInstance) === null || _info_storeInstance === void 0 ? void 0 : _info_storeInstance.constructor;\n return (_DebugComponents_get = DebugComponents.get(component)) === null || _DebugComponents_get === void 0 ? void 0 : _DebugComponents_get.has(StoreCons);\n};\nvar DebugComponents = /* @__PURE__ */ new Map();\nvar DebugStores = /* @__PURE__ */ new Set();\n//# sourceMappingURL=useStoreDebug.js.map\n"],"mappings":";;;;AACA,IAAI,WAAW,OAAO;AACtB,IAAI,YAAY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,CAAC,gBAAgB,IAAI,GAAG,GAAG;EAC7B,gBAAgB,IAAI,qBAAqB,IAAI,IAAI,CAAC;CACpD;CACA,IAAI,SAAS,gBAAgB,IAAI,GAAG;CACpC,OAAO,IAAI,SAAS;CACpB,aAAa,QAAQ,gBAAgB,WAAW;EAC9C,OAAO,WAAW;GAChB,YAAY,OAAO,SAAS;GAC5B,OAAO,OAAO,SAAS;EACzB;CACF,GAAG,CAAC,CAAC;AACP;AACA,IAAI,cAAc,SAAS,WAAW,MAAM;CAC1C,IAAI,qBAAqB;CACzB,IAAI,aAAa,sBAAsB,KAAK,mBAAmB,QAAQ,wBAAwB,KAAK,IAAI,KAAK,IAAI,oBAAoB;CACrI,QAAQ,uBAAuB,gBAAgB,IAAI,SAAS,OAAO,QAAQ,yBAAyB,KAAK,IAAI,KAAK,IAAI,qBAAqB,IAAI,SAAS;AAC1J;AACA,IAAI,kCAAkC,IAAI,IAAI;AAC9C,IAAI,8BAA8B,IAAI,IAAI"}
|
package/dist/esm/comparators.mjs
CHANGED
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
const isEqualSubsetShallow = (a, b, opts) => {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
2
|
+
if (b == null || a == null) return a === b;
|
|
3
|
+
if (typeof a !== typeof b) return false;
|
|
4
|
+
if (typeof b === "object") {
|
|
5
|
+
for (const key in b) {
|
|
6
|
+
const compare = opts?.keyComparators?.[key];
|
|
7
|
+
if (compare ? !compare(a[key], b[key]) : b[key] !== a[key]) {
|
|
8
|
+
return false;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
return true;
|
|
12
|
+
}
|
|
13
|
+
return a === b;
|
|
14
14
|
};
|
|
15
|
+
|
|
15
16
|
export { isEqualSubsetShallow };
|
|
16
17
|
//# sourceMappingURL=comparators.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"comparators.js","names":[],"sources":["esm/comparators.js"],"sourcesContent":["const isEqualSubsetShallow = (a, b, opts) => {\n if (b == null || a == null) return a === b;\n if (typeof a !== typeof b) return false;\n if (typeof b === \"object\") {\n for (const key in b) {\n const compare = opts?.keyComparators?.[key];\n if (compare ? !compare(a[key], b[key]) : b[key] !== a[key]) {\n return false;\n }\n }\n return true;\n }\n return a === b;\n};\nexport {\n isEqualSubsetShallow\n};\n//# sourceMappingURL=comparators.js.map\n"],"mappings":";AAAA,MAAM,wBAAwB,GAAG,GAAG,SAAS;CAC3C,IAAI,KAAK,QAAQ,KAAK,MAAM,OAAO,MAAM;CACzC,IAAI,OAAO,MAAM,OAAO,GAAG,OAAO;CAClC,IAAI,OAAO,MAAM,UAAU;EACzB,KAAK,MAAM,OAAO,GAAG;GACnB,MAAM,UAAU,MAAM,iBAAiB;GACvC,IAAI,UAAU,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,IAAI,EAAE,SAAS,EAAE,MAAM;IAC1D,OAAO;GACT;EACF;EACA,OAAO;CACT;CACA,OAAO,MAAM;AACf"}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
function _type_of(obj) {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
2
|
+
"@swc/helpers - typeof";
|
|
3
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
5
4
|
}
|
|
6
|
-
var isEqualSubsetShallow = function
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
5
|
+
var isEqualSubsetShallow = function(a, b, opts) {
|
|
6
|
+
if (b == null || a == null) return a === b;
|
|
7
|
+
if ((typeof a === "undefined" ? "undefined" : _type_of(a)) !== (typeof b === "undefined" ? "undefined" : _type_of(b))) return false;
|
|
8
|
+
if ((typeof b === "undefined" ? "undefined" : _type_of(b)) === "object") {
|
|
9
|
+
for (var key in b) {
|
|
10
|
+
var _opts_keyComparators;
|
|
11
|
+
var compare = opts === null || opts === void 0 ? void 0 : (_opts_keyComparators = opts.keyComparators) === null || _opts_keyComparators === void 0 ? void 0 : _opts_keyComparators[key];
|
|
12
|
+
if (compare ? !compare(a[key], b[key]) : b[key] !== a[key]) {
|
|
13
|
+
return false;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
return true;
|
|
17
|
+
}
|
|
18
|
+
return a === b;
|
|
20
19
|
};
|
|
20
|
+
|
|
21
21
|
export { isEqualSubsetShallow };
|
|
22
22
|
//# sourceMappingURL=comparators.native.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"file":"comparators.native.js","names":[],"sources":["esm/comparators.native.js"],"sourcesContent":["function _type_of(obj) {\n \"@swc/helpers - typeof\";\n return obj && typeof Symbol !== \"undefined\" && obj.constructor === Symbol ? \"symbol\" : typeof obj;\n}\nvar isEqualSubsetShallow = function(a, b, opts) {\n if (b == null || a == null) return a === b;\n if ((typeof a === \"undefined\" ? \"undefined\" : _type_of(a)) !== (typeof b === \"undefined\" ? \"undefined\" : _type_of(b))) return false;\n if ((typeof b === \"undefined\" ? \"undefined\" : _type_of(b)) === \"object\") {\n for (var key in b) {\n var _opts_keyComparators;\n var compare = opts === null || opts === void 0 ? void 0 : (_opts_keyComparators = opts.keyComparators) === null || _opts_keyComparators === void 0 ? void 0 : _opts_keyComparators[key];\n if (compare ? !compare(a[key], b[key]) : b[key] !== a[key]) {\n return false;\n }\n }\n return true;\n }\n return a === b;\n};\nexport {\n isEqualSubsetShallow\n};\n//# sourceMappingURL=comparators.js.map\n"],"mappings":";AAAA,SAAS,SAAS,KAAK;CACrB;CACA,OAAO,OAAO,OAAO,WAAW,eAAe,IAAI,gBAAgB,SAAS,WAAW,OAAO;AAChG;AACA,IAAI,uBAAuB,SAAS,GAAG,GAAG,MAAM;CAC9C,IAAI,KAAK,QAAQ,KAAK,MAAM,OAAO,MAAM;CACzC,KAAK,OAAO,MAAM,cAAc,cAAc,SAAS,CAAC,QAAQ,OAAO,MAAM,cAAc,cAAc,SAAS,CAAC,IAAI,OAAO;CAC9H,KAAK,OAAO,MAAM,cAAc,cAAc,SAAS,CAAC,OAAO,UAAU;EACvE,KAAK,IAAI,OAAO,GAAG;GACjB,IAAI;GACJ,IAAI,UAAU,SAAS,QAAQ,SAAS,KAAK,IAAI,KAAK,KAAK,uBAAuB,KAAK,oBAAoB,QAAQ,yBAAyB,KAAK,IAAI,KAAK,IAAI,qBAAqB;GACnL,IAAI,UAAU,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,IAAI,EAAE,SAAS,EAAE,MAAM;IAC1D,OAAO;GACT;EACF;EACA,OAAO;CACT;CACA,OAAO,MAAM;AACf"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"configureUseStore.js","names":[],"sources":["esm/configureUseStore.js"],"sourcesContent":["let configureOpts = {};\nfunction configureUseStore(opts) {\n configureOpts = opts;\n}\nexport {\n configureOpts,\n configureUseStore\n};\n//# sourceMappingURL=configureUseStore.js.map\n"],"mappings":";AAAA,IAAI,gBAAgB,CAAC;AACrB,SAAS,kBAAkB,MAAM;CAC/B,gBAAgB;AAClB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"configureUseStore.native.js","names":[],"sources":["esm/configureUseStore.native.js"],"sourcesContent":["var configureOpts = {};\nfunction configureUseStore(opts) {\n configureOpts = opts;\n}\nexport {\n configureOpts,\n configureUseStore\n};\n//# sourceMappingURL=configureUseStore.js.map\n"],"mappings":";AAAA,IAAI,gBAAgB,CAAC;AACrB,SAAS,kBAAkB,MAAM;CAC/B,gBAAgB;AAClB"}
|
package/dist/esm/constants.mjs
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
const UNWRAP_PROXY = /* @__PURE__ */Symbol();
|
|
1
|
+
const UNWRAP_PROXY = /* @__PURE__ */ Symbol();
|
|
2
2
|
const defaultOptions = {
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
once: false,
|
|
4
|
+
selector: void 0
|
|
5
5
|
};
|
|
6
|
+
|
|
6
7
|
export { UNWRAP_PROXY, defaultOptions };
|
|
7
8
|
//# sourceMappingURL=constants.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"constants.js","names":[],"sources":["esm/constants.js"],"sourcesContent":["const UNWRAP_PROXY = /* @__PURE__ */ Symbol();\nconst defaultOptions = {\n once: false,\n selector: void 0\n};\nexport {\n UNWRAP_PROXY,\n defaultOptions\n};\n//# sourceMappingURL=constants.js.map\n"],"mappings":";AAAA,MAAM,eAA+B,uBAAO;AAC5C,MAAM,iBAAiB;CACrB,MAAM;CACN,UAAU,KAAK;AACjB"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
var UNWRAP_PROXY = /* @__PURE__ */Symbol();
|
|
1
|
+
var UNWRAP_PROXY = /* @__PURE__ */ Symbol();
|
|
2
2
|
var defaultOptions = {
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
once: false,
|
|
4
|
+
selector: void 0
|
|
5
5
|
};
|
|
6
|
+
|
|
6
7
|
export { UNWRAP_PROXY, defaultOptions };
|
|
7
8
|
//# sourceMappingURL=constants.native.js.map
|