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

barracks

Package Overview
Dependencies
Maintainers
5
Versions
63
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

barracks - npm Package Compare versions

Comparing version 9.0.0 to 9.1.0

12

index.js

@@ -31,2 +31,4 @@ const mutate = require('xtend/mutable')

var stopped = false
const subscriptions = start._subscriptions = {}

@@ -42,2 +44,3 @@ const reducers = start._reducers = {}

start.use = use
start.stop = stop
return start

@@ -204,2 +207,4 @@

function _send (name, data, caller, cb) {
if (stopped) return
assert.equal(typeof name, 'string', 'barracks._send: name should be a string')

@@ -256,2 +261,9 @@ assert.equal(typeof caller, 'string', 'barracks._send: caller should be a string')

}
// stop an app, essentially turns
// all send() calls into no-ops.
// () -> null
function stop () {
stopped = true
}
}

@@ -258,0 +270,0 @@

2

package.json
{
"name": "barracks",
"version": "9.0.0",
"version": "9.1.0",
"description": "Action dispatcher for unidirectional data flows",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -149,2 +149,11 @@ # barracks

### store.stop()
After an app is "stopped" all subsequent `send()` calls become no-ops.
```js
store.stop()
send('trimBeard') // -> does not call a reducer/effect
```
## Handler signatures

@@ -151,0 +160,0 @@ These are the signatures for the properties that can be passed into a model.

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