From 0fd887e3d1e48c3583603ca726e9f9a26fad9a63 Mon Sep 17 00:00:00 2001 From: Artur Arseniev Date: Fri, 25 Aug 2023 14:07:01 +0400 Subject: [PATCH] Update HTMLParseResult --- src/parser/model/ParserHtml.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/parser/model/ParserHtml.ts b/src/parser/model/ParserHtml.ts index b53bdff74..db5f86d80 100644 --- a/src/parser/model/ParserHtml.ts +++ b/src/parser/model/ParserHtml.ts @@ -9,7 +9,7 @@ import BrowserParserHtml from './BrowserParserHtml'; type StringObject = Record; type HTMLParseResult = { - html?: ComponentDefinitionDefined | ComponentDefinitionDefined[]; // TODO replace with components + html: ComponentDefinitionDefined | ComponentDefinitionDefined[]; // TODO replace with components css?: CssRuleJSON[]; }; @@ -301,7 +301,7 @@ const ParserHtml = (em?: EditorModel, config: ParserConfig & { returnArray?: boo */ parse(str: string, parserCss?: any, opts: HTMLParserOptions = {}) { const conf = em?.get('Config') || {}; - const res: HTMLParseResult = {}; + const res: HTMLParseResult = { html: [] }; const cf: ObjectAny = { ...config, ...opts }; const options = { ...config.optionsHtml,