javascript - Reactivity in jQuery-generated contenteditable elements (Meteor 0.8.0) -


i've been having problems contenteditable elements generated via jquery since meteor 0.8.0 (blaze template engine).

this setup (i'm using medium editor):

post_page.html:

<template name="postpage">   <div class="sidebar col-md-4">     {{#each posts}}       {{> postitem}}     {{/each}}     <a class="save-all" href="javascript:;"><span class="glyphicon glyphicon glyphicon-save"></span></a>   </div>    <div class="mainbar col-md-12">   <form class="form" role="form">     <div class="form-group">       <div name="content" class="form-control" id="input-content">{{{content}}}</div>     </div>     <button type="submit" class="btn btn-default submit">submit</button>   </form>   </div> </template> 

post_page.js:

template.postpage.rendered = function() {   var editor;   editor = new mediumeditor("#input-content", {     placeholder: ""   }); }; 

post_item.html:

<template name="postitem">   <div class="post clearfix {{title}}">     <div class="post-buttons">       <a class="move-up" href="javascript:;"><span class="glyphicon glyphicon-arrow-up"></span></a>       <a class="move-down" href="javascript:;"><span class="glyphicon glyphicon-arrow-down"></span></a>     </div>     <h2><a class="open-post" href="{{pathfor 'postpage'}}">{{title}}</a></h2>   </div> </template> 

routes.js:

this.route("postpage", {   path: "/posts/:_id",   data: function() {     return posts.findone(this.params._id);   } }); 

even though click in item in posts list, {{{content}}} inside contenteditable div doesn't change (remains same time). reason, reactivity not working in case.

any ideas of how solve this?


Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -