diff --git a/packages/liquid-html-parser/src/grammar.ts b/packages/liquid-html-parser/src/grammar.ts index 79675ad7..18167b8e 100644 --- a/packages/liquid-html-parser/src/grammar.ts +++ b/packages/liquid-html-parser/src/grammar.ts @@ -53,4 +53,5 @@ export const TAGS_WITHOUT_MARKUP = [ 'continue', 'comment', 'raw', + 'doc', ]; diff --git a/packages/liquid-html-parser/src/stage-2-ast.spec.ts b/packages/liquid-html-parser/src/stage-2-ast.spec.ts index d88a557e..84848ccb 100644 --- a/packages/liquid-html-parser/src/stage-2-ast.spec.ts +++ b/packages/liquid-html-parser/src/stage-2-ast.spec.ts @@ -1224,6 +1224,7 @@ describe('Unit: Stage 2 (AST)', () => { ast = toLiquidAST(`{% doc %}{% enddoc %}`); expectPath(ast, 'children.0.type').to.eql('LiquidRawTag'); expectPath(ast, 'children.0.name').to.eql('doc'); + expectPath(ast, 'children.0.markup').toEqual(''); expectPath(ast, 'children.0.body.value').to.eql(''); expectPath(ast, 'children.0.body.type').toEqual('RawMarkup'); expectPath(ast, 'children.0.body.nodes').toEqual([]);