ampersand-view
Advanced tools
Comparing version 6.0.10 to 6.0.11
@@ -20,2 +20,5 @@ var State = require('ampersand-state'); | ||
this._initializeBindings(); | ||
if (attrs.el && !this.autoRender) { | ||
this._handleElementChange(); | ||
} | ||
this._initializeSubviews(); | ||
@@ -22,0 +25,0 @@ this.initialize.apply(this, arguments); |
{ | ||
"name": "ampersand-view", | ||
"description": "A smart base view for Backbone apps, to make it easy to bind collections and properties to the DOM.", | ||
"version": "6.0.10", | ||
"version": "6.0.11", | ||
"author": "Henrik Joreteg <henrik@andyet.net>", | ||
@@ -17,3 +17,3 @@ "browser": "./ampersand-view.js", | ||
"matches-selector": "^1.0.0", | ||
"underscore": "^1.6.0" | ||
"underscore": "1.6.0" | ||
}, | ||
@@ -20,0 +20,0 @@ "devDependencies": { |
@@ -625,1 +625,21 @@ var test = require('tape'); | ||
}); | ||
test('events are bound if there is an el in the constructor', function (t) { | ||
t.plan(1); | ||
var event = document.createEvent("MouseEvent"); | ||
var View = AmpersandView.extend({ | ||
template: function () { | ||
return document.createElement('div'); | ||
}, | ||
events: { | ||
'click div': 'divClicked' | ||
}, | ||
divClicked: function (e) { | ||
t.ok(true, 'event fired'); | ||
t.end(); | ||
} | ||
}); | ||
var view = new View({el: document.createElement('div')}); | ||
event.initMouseEvent('click'); | ||
view.el.dispatchEvent(event); | ||
}); |
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
60971
1111
+ Addedunderscore@1.6.0(transitive)
- Removedunderscore@1.13.7(transitive)
Updatedunderscore@1.6.0