diff --git a/packages/astro/src/compiler/codegen/index.ts b/packages/astro/src/compiler/codegen/index.ts index a89033249..e36b0082e 100644 --- a/packages/astro/src/compiler/codegen/index.ts +++ b/packages/astro/src/compiler/codegen/index.ts @@ -673,7 +673,7 @@ async function compileHtml(enterNode: TemplateNode, state: CodegenState, compile } }, }).then(() => { - const content = buffers.out.replace(/^\,/, '').replace(/\,\)/g, ')').replace(/\,+/g, ',').replace(/\)h/g, '),h') + const content = buffers.out.replace(/^\,/, '').replace(/\,\)/g, ')').replace(/\,+/g, ',').replace(/\)h/g, '),h'); buffers.out = ''; buffers.markdown = ''; return resolve(content); diff --git a/packages/astro/test/astro-markdown.test.js b/packages/astro/test/astro-markdown.test.js index 31170d034..cadb255bd 100644 --- a/packages/astro/test/astro-markdown.test.js +++ b/packages/astro/test/astro-markdown.test.js @@ -65,7 +65,7 @@ Markdown('Renders recursively', async ({ runtime }) => { if (result.error) throw new Error(result.error); console.log(result.contents); - + const $ = doc(result.contents); assert.equal($('.a > h1').text(), 'A', 'Rendered title .a correctly'); assert.equal($('.b > h1').text(), 'B', 'Rendered title .b correctly');