TypeError: Result of expression 'this._configure' [undefined] is not a function.
I keep running into this error any time I extend Backbone.View
my app structure looks like :
//index.js
$(function(){
window.Project = Backbone.Model.extend({});
window.ProjectCollection = Backbone.Collection.extend({});
window.projects = new ProjectCollection;
window.ProjectView = Backbone.View.extend({});
window.view = ProjectView({});
window.view.render();
});
Even with this blank structure I still get the error, and when I have all my code filled in I get the exact same error
Am I missing a dependancy? in my index.html I load the following in order:
jquery.js
underscore.js
backbone.js
(and at the bottom of my body) index.js
And if I take the 'window' off of my variables i get the same error.
No matter how I approach backbone.js I keep getting this same error... how do I fix this?
Try
window.view = new ProjectView;
instead of
window.view = ProjectView({});
I was recently seeing this error too TypeError: this._configure is not a function
and it was because I had:
var myView = someView();
instead of:
var myView = new someView();
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With