Skip to content

Commit

Permalink
Enable TinyMCE sanitization when setting HTML content
Browse files Browse the repository at this point in the history
We were previously disabling TinyMCE sanitization by calling setContent
with `{ format: 'raw' }`. Doing so, however, causes issues when
setContent is called with prettified HTML, e.g. when a list block is
updated.
  • Loading branch information
noisysocks committed Jan 5, 2018
1 parent a6948bd commit 5d4e19d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion blocks/editable/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -705,7 +705,7 @@ export default class Editable extends Component {
}

content = renderToString( content );
this.editor.setContent( content, { format: 'raw' } );
this.editor.setContent( content );
}

getContent() {
Expand Down

0 comments on commit 5d4e19d

Please sign in to comment.