mirror of
https://github.com/codex-team/editor.js
synced 2024-06-10 09:52:36 +02:00
Issue #2575 add await for clear() method execution in renderFromHTML
This commit is contained in:
parent
b8cfcaec26
commit
d29cfce4e3
|
@ -205,8 +205,8 @@ export default class BlocksAPI extends Module {
|
|||
* @param {string} data - HTML string to render
|
||||
* @returns {Promise<void>}
|
||||
*/
|
||||
public renderFromHTML(data: string): Promise<void> {
|
||||
this.Editor.BlockManager.clear();
|
||||
public async renderFromHTML(data: string): Promise<void> {
|
||||
await this.Editor.BlockManager.clear();
|
||||
|
||||
return this.Editor.Paste.processText(data, true);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue