UNPKG

@tacky/store

Version:

State management framework based on react

22 lines (21 loc) 624 B
import _typeof from "@babel/runtime/helpers/esm/typeof"; /** * Check if a string starts with $ or _ */ export function isReserved(str) { var c = (str + '').charCodeAt(0); return c === 0x24 || c === 0x5F; } export function isSupportProxy() { return typeof Proxy !== 'undefined'; } export function isSymbol(symbol) { return _typeof(symbol) === 'symbol'; } export function isSupportSymbol() { return typeof Symbol !== 'undefined'; } export var toObjectTypeString = function toObjectTypeString(value) { return Object.prototype.toString.call(value); }; export var stateDecoRegExp = /^\[object (?:Object|Array)\]$/;