Comparing version 0.3.2 to 0.3.3
{ | ||
"name": "temple", | ||
"version": "0.3.2", | ||
"version": "0.3.3", | ||
"description": "A modern JavaScript view framework.", | ||
@@ -5,0 +5,0 @@ "repo": "BeneathTheInk/Temple", |
{ | ||
"name": "temple", | ||
"version": "0.3.2", | ||
"version": "0.3.3", | ||
"description": "A modern JavaScript view framework.", | ||
@@ -5,0 +5,0 @@ "repository": "BeneathTheInk/Temple", |
@@ -284,13 +284,15 @@ var Events = require("./events"), | ||
// stop existing mount | ||
this.stop(); | ||
Deps.nonreactive(function() { | ||
// stop existing mount | ||
this.stop(); | ||
// init the function event methods | ||
this._initEventMethods(); | ||
// init the function event methods | ||
this._initEventMethods(); | ||
// the first event in the cycle, before everything else | ||
this.trigger("mount:before", args); | ||
// the first event in the cycle, before everything else | ||
this._mounting = true; | ||
this.trigger("mount:before", args); | ||
}, this); | ||
// the autorun computation | ||
this._mounting = true; | ||
comp = this._comp = this.autorun(function(comp) { | ||
@@ -336,7 +338,8 @@ // only render event without bindings | ||
// remaining mount events happen after the first render | ||
this.trigger("mount", comp, args); | ||
delete this._mounting; | ||
Deps.nonreactive(function() { | ||
this.trigger("mount", comp, args); | ||
this.trigger("mount:after", comp, args); | ||
delete this._mounting; | ||
}, this); | ||
this.trigger("mount:after", comp, args); | ||
return this; | ||
@@ -348,7 +351,7 @@ }, | ||
isMounted: function() { | ||
return this._comp != null && !this._mounting; | ||
return this.isMounting() || this._comp != null; | ||
}, | ||
isMounting: function() { | ||
return this._comp != null && this._mounting; | ||
return !!this._mounting; | ||
}, | ||
@@ -361,3 +364,3 @@ | ||
invalidate: function() { | ||
if (this._comp != null) this._comp.invalidate(); | ||
if (this.isMounted()) this._comp.invalidate(); | ||
return this; | ||
@@ -367,3 +370,3 @@ }, | ||
stop: function() { | ||
if (this._comp != null) this._comp.stop(); | ||
if (this.isMounted()) this._comp.stop(); | ||
return this; | ||
@@ -370,0 +373,0 @@ }, |
@@ -17,3 +17,3 @@ var Binding = require("./binding"), | ||
// static properties/methods | ||
Temple.VERSION = "0.3.2"; | ||
Temple.VERSION = "0.3.3"; | ||
Temple.util = util; | ||
@@ -20,0 +20,0 @@ Temple.Events = require("./events"); |
{ | ||
"name": "templejs", | ||
"version": "0.3.2", | ||
"version": "0.3.3", | ||
"description": "A modern JavaScript view framework.", | ||
@@ -5,0 +5,0 @@ "author": "Beneath the Ink <info@beneaththeink.com>", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
47325
1377