canjs / can-23

A CanJS 2.3 stache built from mostly CanJS 6 parts.
0 stars 1 forks source link

#each doesn't loop through keys with `.` in them correctly #14

Open justinbmeyer opened 2 years ago

justinbmeyer commented 2 years ago
x = new can.Map({ "foo.bar": "baz" });
y = can.stache(`{{#each this}}{{%key}} {{this}}<br>{{/each}}`)
$('<div>').append(y(x)).html(); 
// '\x3C!--Observation<{{#each this}}>-->foo.bar <br>\x3C!--/Observation<{{#each this}}>-->'

The value of "baz" won't be printed