react-hooks-global-states
Version:
This is a package to easily handling global-state across your react-components using hooks.
1 lines • 941 B
JavaScript
var t;t=()=>(()=>{"use strict";var t={};return((t,e)=>{var n,r,o,u;Object.defineProperty(e,"__esModule",{value:!0}),e.uniqueId=void 0,e.uniqueId=(n=0,r=function(){return n===Number.MAX_SAFE_INTEGER&&(n=0),n++},o=function(t,e){return(null!=t?t:"")+Date.now().toString(36)+e.toString(36)},(u=function(t){return o(t,r())}).for=function(t){var e=function(){return o(t,r())};return e.is=function(e){return"string"==typeof e&&e.startsWith(t)},e.assert=function(n){if(!e.is(n))throw new Error('The value "'.concat(String(n),'" does not match the expected prefix "').concat(String(t),'"'))},e.strict=function(){return e},e},u.of=function(){return u.for("")},u.strict=function(){return u},u),e.default=e.uniqueId})(0,t),t})(),"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports["react-hooks-global-states"]=t():this["react-hooks-global-states"]=t();