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

@mmckegg/mutant

Package Overview
Dependencies
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mmckegg/mutant - npm Package Compare versions

Comparing version 3.4.1 to 3.5.0

6

computed.js

@@ -180,3 +180,7 @@ /* A lazy binding take on computed */

this.lazy = false
this.update()
if (this.opts && this.opts.nextTick && this.live && this.lazy) {
this.onUpdate() // use cached value to make more responsive
} else {
this.update()
}
if (this.inner) {

@@ -183,0 +187,0 @@ this.outputValue = resolve(this.inner)

11

lib/lazy-watcher.js
module.exports = function (update, onBind, onUnbind) {
var lazy = false
var context = this

@@ -21,3 +22,3 @@ var obj = {

onUpdate: function () {
if (update()) {
if (update.apply(context)) {
broadcast()

@@ -30,3 +31,3 @@ }

lazy = false
update()
update.apply(context)
}

@@ -36,3 +37,3 @@ },

getValue: function () {
obj.checkUpdated()
obj.checkUpdated.apply(context)
return obj.value

@@ -51,3 +52,3 @@ },

lazy = true
onBind()
onBind.apply(context)
}

@@ -64,3 +65,3 @@

obj.live = false
onUnbind()
onUnbind.apply(context)
}

@@ -67,0 +68,0 @@ }

{
"name": "@mmckegg/mutant",
"version": "3.4.1",
"version": "3.5.0",
"description": "",

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

module.exports = watch
function watch (observable, listener) {
listener = listener || noop
if (typeof observable === 'function') {

@@ -5,0 +6,0 @@ var remove = observable(listener)

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