Content updates only when didInsertElement gets triggered.
Example
this.route("static", { path: "static/:page" });
{link-to "static" "page1"} ...
{link-to "static" "page2"} ...
{{summer-note height=500 btnSize=bs-sm content=model.content focus=true header="Example"}}
model(params) {
return this.store.find('static', params.page);
},
The first time static/page1 and static/page2 load, content displays fine. After that, clicking again (say) page1, the editor will still display page2's content. Furthermore, if you click inside the editor, it will replace page1's content with page2's content.
Workaround
The workaround is to force the Ember Data to query the API again, forcing the outlet to redraw and didInsertElement to re-fire.
model(params) {
return this.store.fetch('staticpage', params.page);
},
Content updates only when didInsertElement gets triggered.
Example
The first time
static/page1andstatic/page2load, content displays fine. After that, clicking again (say)page1, the editor will still displaypage2's content. Furthermore, if you click inside the editor, it will replacepage1's content withpage2's content.Workaround
The workaround is to force the
Ember Datato query the API again, forcing the outlet to redraw and didInsertElement to re-fire.