These are chat archives for canjs/canjs

22nd
Oct 2016
Gregg Roemhildt
@roemhildtg
Oct 22 2016 01:48
Playing around with the new canjs 3, and so far, it looks like the migration should be fairly straightforward :+1:
Had a question on partials though, it looks like they've changed a bit. Am I still able to do something like this?
partials = {
     a: stache('<p>{{something}}</p>'),
     b: stache('<a href="{{url}}">{{text}}</a>')
};
<!--in template-->
<div class="wrapper">
{{>partials.a}}
{{>partials.b}}
</div>
Justin Meyer
@justinbmeyer
Oct 22 2016 02:08
you should be able to
Gregg Roemhildt
@roemhildtg
Oct 22 2016 03:34

Hm, I'm getting an error here in can-stache:

var templates = {};
stache.from = mustacheCore.getTemplateById = function(id){  //id='document-fragment'
    if(!templates[id]) {
        var el = DOCUMENT().getElementById(id);
        templates[id] = stache(el.innerHTML);
    }
    return templates[id];
};

Is there a jsbin starter for 3.0 set up?

Frank Lemanschik
@frank-dspeed
Oct 22 2016 19:41
Gregg Roemildt i would suggest you the TodoMVC app in branch can3 i think its the most forwarded example
Kevin Phillips
@phillipskevin
Oct 22 2016 19:46
Thomas Sieverding
@Bajix
Oct 22 2016 19:51
@justinbmeyer Are there any CanJS Hybrid app frameworks in development that you’re aware of?