mirror of
https://github.com/codex-team/editor.js
synced 2026-03-15 23:25:47 +01:00
Fix rerender method
This commit is contained in:
parent
5df9233fb5
commit
3345d0e2be
4 changed files with 7 additions and 7 deletions
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -203,9 +203,9 @@ module.exports = (function (renderer) {
|
|||
};
|
||||
|
||||
/**
|
||||
* Clears redactor area and render blocks from editor.state.blocks if makeBlocksFromData param is true
|
||||
*
|
||||
* @param makeBlocksFromData
|
||||
* @param {bool} makeBlocksFromData - if true, renders blocks from editor.state.blocks data,
|
||||
* else adds only initial plugin block
|
||||
*/
|
||||
renderer.rerender = function (makeBlocksFromData) {
|
||||
|
||||
|
|
@ -215,12 +215,12 @@ module.exports = (function (renderer) {
|
|||
|
||||
if (makeBlocksFromData) {
|
||||
|
||||
editor.ui.addInitialBlock();
|
||||
renderer.makeBlocksFromData();
|
||||
return;
|
||||
|
||||
}
|
||||
|
||||
renderer.makeBlocksFromData();
|
||||
editor.ui.addInitialBlock();
|
||||
|
||||
};
|
||||
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue