Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

simpler-state

Package Overview
Dependencies
Maintainers
1
Versions
62
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

simpler-state - npm Package Compare versions

Comparing version 2.0.0-pre.4 to 2.0.0-pre.5

2

es/core/entity.js

@@ -50,3 +50,3 @@ import { strictEqual } from './equality';

if (alias !== '@@DEVTOOLS') onSet(entity, alias !== null && alias !== void 0 ? alias : '<anonymous>');
if (alias !== '@@DEVTOOLS') onSet(entity, alias ?? '<anonymous>');
};

@@ -53,0 +53,0 @@ }

@@ -40,7 +40,5 @@ function getLocalStorage() {

export default function persistence(key, options = {}) {
var _a;
if (typeof key !== 'string') throw new Error('Persistence requires a string key.');
let storage;
const storageOption = (_a = options.storage) !== null && _a !== void 0 ? _a : 'local';
const storageOption = options.storage ?? 'local';
if (storageOption === 'local') storage = getLocalStorage();else if (storageOption === 'session') storage = getSessionStorage();else storage = validateCustomStorage(storageOption);

@@ -47,0 +45,0 @@

@@ -10,7 +10,7 @@ import { getMutableMap, initRegistry, updateRegistry, watchRegistry } from './registry';

export function initInspector() {
var _a, _b;
var _window$__REDUX_DEVTO;
devTools = (_b = (_a = window.__REDUX_DEVTOOLS_EXTENSION__) === null || _a === void 0 ? void 0 : _a.connect({
devTools = ((_window$__REDUX_DEVTO = window.__REDUX_DEVTOOLS_EXTENSION__) == null ? void 0 : _window$__REDUX_DEVTO.connect({
name: document.title
})) !== null && _b !== void 0 ? _b : null;
})) ?? null;

@@ -17,0 +17,0 @@ if (devTools) {

@@ -70,3 +70,3 @@ "use strict";

if (alias !== '@@DEVTOOLS') (0, _inspector.onSet)(entity, alias !== null && alias !== void 0 ? alias : '<anonymous>');
if (alias !== '@@DEVTOOLS') (0, _inspector.onSet)(entity, alias != null ? alias : '<anonymous>');
};

@@ -73,0 +73,0 @@ }

@@ -47,2 +47,4 @@ "use strict";

function persistence(key, options) {
var _options$storage;
if (options === void 0) {

@@ -52,7 +54,5 @@ options = {};

var _a;
if (typeof key !== 'string') throw new Error('Persistence requires a string key.');
var storage;
var storageOption = (_a = options.storage) !== null && _a !== void 0 ? _a : 'local';
var storageOption = (_options$storage = options.storage) != null ? _options$storage : 'local';
if (storageOption === 'local') storage = getLocalStorage();else if (storageOption === 'session') storage = getSessionStorage();else storage = validateCustomStorage(storageOption);

@@ -59,0 +59,0 @@

@@ -25,7 +25,7 @@ "use strict";

function initInspector() {
var _a, _b;
var _window$__REDUX_DEVTO, _window$__REDUX_DEVTO2;
devTools = (_b = (_a = window.__REDUX_DEVTOOLS_EXTENSION__) === null || _a === void 0 ? void 0 : _a.connect({
devTools = (_window$__REDUX_DEVTO = (_window$__REDUX_DEVTO2 = window.__REDUX_DEVTOOLS_EXTENSION__) == null ? void 0 : _window$__REDUX_DEVTO2.connect({
name: document.title
})) !== null && _b !== void 0 ? _b : null;
})) != null ? _window$__REDUX_DEVTO : null;

@@ -32,0 +32,0 @@ if (devTools) {

{
"name": "simpler-state",
"version": "2.0.0-pre.4",
"version": "2.0.0-pre.5",
"description": "The simplest app state management for React",

@@ -5,0 +5,0 @@ "keywords": [

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc