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

@uppy/store-default

Package Overview
Dependencies
Maintainers
6
Versions
42
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@uppy/store-default - npm Package Compare versions

Comparing version 3.0.3 to 3.0.4

23

lib/index.js
function _classPrivateFieldLooseBase(receiver, privateKey) { if (!Object.prototype.hasOwnProperty.call(receiver, privateKey)) { throw new TypeError("attempted to use private field on non-instance"); } return receiver; }
var id = 0;
function _classPrivateFieldLooseKey(name) { return "__private_" + id++ + "_" + name; }
const packageJson = {
"version": "3.0.3"
"version": "3.0.4"
};

@@ -13,7 +10,4 @@ /**

*/
var _callbacks = /*#__PURE__*/_classPrivateFieldLooseKey("callbacks");
var _publish = /*#__PURE__*/_classPrivateFieldLooseKey("publish");
class DefaultStore {

@@ -30,21 +24,18 @@ constructor() {

}
getState() {
return this.state;
}
setState(patch) {
const prevState = { ...this.state
const prevState = {
...this.state
};
const nextState = { ...this.state,
const nextState = {
...this.state,
...patch
};
this.state = nextState;
_classPrivateFieldLooseBase(this, _publish)[_publish](prevState, nextState, patch);
}
subscribe(listener) {
_classPrivateFieldLooseBase(this, _callbacks)[_callbacks].add(listener);
return () => {

@@ -54,5 +45,3 @@ _classPrivateFieldLooseBase(this, _callbacks)[_callbacks].delete(listener);

}
}
function _publish2() {

@@ -62,3 +51,2 @@ for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {

}
_classPrivateFieldLooseBase(this, _callbacks)[_callbacks].forEach(listener => {

@@ -68,4 +56,3 @@ listener(...args);

}
DefaultStore.VERSION = packageJson.version;
export default DefaultStore;
{
"name": "@uppy/store-default",
"description": "The default simple object-based store for Uppy.",
"version": "3.0.3",
"version": "3.0.4",
"license": "MIT",

@@ -19,3 +19,3 @@ "main": "lib/index.js",

"devDependencies": {
"@jest/globals": "^29.0.0"
"vitest": "^0.34.5"
},

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

@@ -1,2 +0,2 @@

import { describe, expect, it } from '@jest/globals'
import { describe, expect, it } from 'vitest'
import assert from 'node:assert'

@@ -3,0 +3,0 @@ import DefaultStore from './index.js'

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