_cid Added to Object
I have an object with a few properties. When I add that object to a can.Map the property "_cid" is added to my object.This is happening after my upgrade to 2.0.2Is this expected?I don't want it there....
View ArticleRe : _cid Added to Object
It's this line that's adding ithttps://github.com/bitovi/canjs/blob/master/map/map.js#L149
View ArticlePassing scope value to global helper in can.Component
How do I pass a value from the can.Component's scope as the parameter to a mustache global helper function?<h1>{{l10n appTitle}}</h1>l10n is the global helper and appTitle is defined on the...
View ArticleRe : Passing scope value to global helper in can.Component
Create fiddle.BTW I would recommend you make your own component for l10n and i18n for example I made:<t-text dict="dict" lang="en" key="appTitle"></t-text>where I pass a dictionary, lang...
View ArticleRe : Passing scope value to global helper in can.Component
scope attribute is passed as its compute to helper, not sure if you consider this. Fiddle would help.
View ArticleRe : Passing scope value to global helper in can.Component
http://jsfiddle.net/thecountofzero/qYdwR/1115/
View ArticleRe : Passing scope value to global helper in can.Component
As I've mentioned above scope attribute (as any can.Map's/Obeserve attribute) is passed to helper as its compute value (it was made to allow two-way binding), so to get value you should use key(), not...
View ArticleDo I Have A Memory Leak?
Let me first put the disclaimer up here that the existence of this post by no means indicates that there is actually a memory leak, but I wanted to get some experts's opinions.Perhaps it's just the...
View ArticleRe : Live Binding Remnants
I forgot to mention that if you use <%== CODE %> magic tags instead of <%= CODE %>, then the bindings do get torn down.
View ArticleRe : Declaring default attributes from upper level scopes
you can overwrite the scope property to do pretty-much whatever you want:look at scope's function(attrs, parentScope, element)signaturescope: function(attrs, parentScope, element){ return new...
View ArticleRe : Live Binding Remnants
Yes. Updated the fiddle to use a can.Maphttp://jsfiddle.net/thecountofzero/RusPR/3/
View ArticleRe : Swallowing Console Errors?
Is it supposed to do that? I have the same issue. Should I just put a console.log in the catch?
View ArticleRe : Live Binding Remnants
Here is a breaking test which can be added to ejs_test.jstest("_bindings removed when element removed", function() { var template = can.view.ejs('<div id="game"><% if(game.attr("league")) {...
View ArticleRe : Live Binding Remnants
That can't be added because it is using jQuery directly.Also, what happens if the parent element is removed from the page? Sometimes, bindings are only removed if the parent element is removed. This...
View ArticleRe : Live Binding Remnants
I take some of that back ... setup calls listen .. not sure what is happening.
View Article