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

piral-containers

Package Overview
Dependencies
Maintainers
1
Versions
933
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

piral-containers - npm Package Compare versions

Comparing version 0.9.3 to 0.9.4

6

lib/actions.js

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

function createState(ctx, id, data) {
react_atom_1.swap(ctx, state => (Object.assign({}, state, { containers: piral_core_1.withKey(state.containers, id, data) })));
react_atom_1.swap(ctx, state => (Object.assign(Object.assign({}, state), { containers: piral_core_1.withKey(state.containers, id, data) })));
}
exports.createState = createState;
function destroyState(ctx, id) {
react_atom_1.swap(ctx, state => (Object.assign({}, state, { containers: piral_core_1.withoutKey(state.containers, id) })));
react_atom_1.swap(ctx, state => (Object.assign(Object.assign({}, state), { containers: piral_core_1.withoutKey(state.containers, id) })));
}

@@ -18,3 +18,3 @@ exports.destroyState = destroyState;

const newState = dispatch(oldState);
return Object.assign({}, state, { containers: piral_core_1.withKey(state.containers, id, Object.assign({}, oldState, newState)) });
return Object.assign(Object.assign({}, state), { containers: piral_core_1.withKey(state.containers, id, Object.assign(Object.assign({}, oldState), newState)) });
});

@@ -21,0 +21,0 @@ }

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

context.defineActions(actions);
react_atom_1.swap(context.state, state => (Object.assign({}, state, { containers: {} })));
react_atom_1.swap(context.state, state => (Object.assign(Object.assign({}, state), { containers: {} })));
return (api, target) => {

@@ -16,0 +16,0 @@ let containers = 0;

import * as React from 'react';
import { StateConnectorProps } from './types';
export declare function withPiletState<TState, TAction, TProps>(Component: React.ComponentType<TProps & StateConnectorProps<TState, TAction>>, id: string, actions: TAction): React.FunctionComponent<TProps>;
export declare function withPiletState<TState, TAction, TProps>(Component: React.ComponentType<TProps & StateConnectorProps<TState, TAction>>, id: string, actions: TAction): React.FC<TProps>;
{
"name": "piral-containers",
"version": "0.9.3",
"version": "0.9.4",
"description": "Plugin for creating a pilet state container in Piral.",

@@ -40,3 +40,3 @@ "keywords": [

"devDependencies": {
"piral-core": "^0.9.3"
"piral-core": "^0.9.4"
},

@@ -46,3 +46,3 @@ "peerDependencies": {

},
"gitHead": "a079ff637821eeacd28f1209593b778e370d0366"
"gitHead": "2426a2466d490035811e382e871f1a019eae3513"
}

Sorry, the diff of this file is not supported yet

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