Re : Maximum call stack size exceeded on model destroy
Here is a breaking test case:test("Max Callstack Exceeded", function() { Policy = can.Model({ id: 'name', attributes: { cacheDetails: 'Cache.model' },...
View Articlerender view with data from two models
Hi,I found how to render a single vie with data from X models, although still an issue...using:can.view('todosAndUser', { todos: Todo.findAll(), user: User.findOne({id: 5})}).then(function(frag) {...
View ArticleRe : In can 2.0.3, namespacing events does not work
Not anymore. We use our own, independent event system. Sent from my iPhoneOn Dec 2, 2013, at 12:55 PM, JavaScriptMVC Forum <noreply@zohodiscussions.com> wrote:
View ArticleRe : Maximum call stack size exceeded on model destroy
Anyway you can clean that up a bit? Ex: not creating a global (Policy). Remove unnecessary features like setting the id attribute. I doubt fixtures or a findAll method are needed. Sent from my...
View ArticleRe : Maximum call stack size exceeded on model destroy
Ok, so I cleaned it up "a little" (removed fixtures and globals) and I uncovered an interesting fact. When I got rid of the globals as in the example below, I do not see the error. But if you remove...
View ArticleRe : render view with data from two models
If you want to load them in parallel you can use $.when:$.when(Todo.findAll({}), User.findOne({id : 5}).then(function(todos, user){ ...do stuff})
View ArticleRe : can.Component inserted event fires twice on the same element
Here is a breaking fiddle:http://jsfiddle.net/thecountofzero/8DeMY/
View ArticleRe : can.Component inserted event fires twice on the same element
I would create an issue on github that is definitely a bug.
View ArticleRe : can.Component inserted event fires twice on the same element
Well I've encountered it in my app now which is without can.Control at all. Event this simple fiddle http://jsfiddle.net/8DeMY/3/ produces the bug, it strange that i didn't noticed it before.Perhaps...
View ArticleRe : Maximum call stack size exceeded on model destroy
The reason for the globals was so that associations (attributes) would work. And it's the associations that are ultimately causing the maximum callstack errors. That's why when I make them not global,...
View ArticleRe : Steal Build Error
I had the same problem.Your suggestion seemed to have solved the problem for me too.
View ArticleRe : Steal Build Error
That parsing stuff is pretty old code. I think it should probably be replaced. Even though you get errors it shouldn't prevent the build from succeeded. It just won't remove steal.dev stuff, if you're...
View Articlecan.Component and "jQuery Mobile component refresh"
One of the things you have to do when using jQuery Mobile, is to refresh certain components in order to style them. This needs to be done when such components are inserted to the DOM after the jQuery...
View ArticleI'm confused what can.Components are meant for
Are they meant for building things like video players and custom control elements or to replace what we used can.Control for?Take a notifications widget; you can add new dialogs to it through something...
View ArticleRe : I'm confused what can.Components are meant for
Component's replace can.Control except for high-performance widgets like a grid. But a Component has a Control within it (the events object) so you can even create a high-performance Grid with a...
View ArticleBest practice for passing references to a can.Component instance
For example, a global "growl" style notifications widget. Would we use a global variable or pass a reference with something like $("some-other-component").scope().notifications = notificationsInstance?
View ArticleRe : Best practice for passing references to a can.Component instance
The beautiful thing about using a data, event driven architecture is that you generally don't ever actually need to interact with the components that consume that data, only the data itself. You have a...
View ArticleRe : can.Component and "jQuery Mobile component refresh"
You should be able to accomplish this by using helper functions, and leveraging their element callbacks to setup your logic.
View Article