I hava an textarea and I am using tinyMCE on that textarea.
What I am doing actually is that when the page is opened, I am populating the textarea with some text, and af
I had the same problem solved by making sure the setContent
was done after the document is ready, so first;
script(type="text/javascript").
tinymce.init({
selector: '#title',
height: 350,
menubar: false
});
then
script(type='text/javascript').
$(document).ready(function(){
tinymce.get('title').setContent('someText is html');
})
Above is code for pug, but the key is -as mentioned- to load it on document ready.