New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

atomic-state

Package Overview
Dependencies
Maintainers
2
Versions
170
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

atomic-state - npm Package Compare versions

Comparing version 1.3.5 to 1.3.6

9

index.js

@@ -81,6 +81,10 @@ "use strict";

var hookCall = (0, react_1.useMemo)(function () { return "".concat(Math.random()).split(".")[1]; }, []);
var isNumber = typeof init.default === "number";
var isDefined = typeof init.default !== "undefined";
var initialValue = (function getInitialValue() {
var isFunction = typeof init.default === "function";
var initVal = init.default || isNumber ? init.default : defaultAtomsValues[init.name];
var initVal = isDefined
? typeof defaultAtomsValues[init.name] === "undefined"
? init.default
: defaultAtomsValues[init.name]
: defaultAtomsValues[init.name];
try {

@@ -175,2 +179,3 @@ return init.localStoragePersistence

var newValue = typeof v === "function" ? v(previous) : v;
defaultAtomsValues[init.name] = newValue;
notify(init.name, hookCall, newValue);

@@ -177,0 +182,0 @@ // Finally update state

{
"name": "atomic-state",
"version": "1.3.5",
"description": "State managment library for React and React Native apps",
"version": "1.3.6",
"description": "State managment library for React",
"main": "index.js",

@@ -6,0 +6,0 @@ "repository": {

Sorry, the diff of this file is not supported yet

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