summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar ewatch <ewatchhu@gmx.de> 2021-06-18 00:19:21 +0200
committerGravatar GitHub <noreply@github.com> 2021-06-17 17:19:21 -0500
commit2b51e9e4b33ad75d4b583dda178bfbf56a080524 (patch)
treec8010b9ee232607ec115668125b2ce22563b6712
parentff7ec2fc021a549bcf7e31624b6c2a8f01042a07 (diff)
downloadastro-2b51e9e4b33ad75d4b583dda178bfbf56a080524.tar.gz
astro-2b51e9e4b33ad75d4b583dda178bfbf56a080524.tar.zst
astro-2b51e9e4b33ad75d4b583dda178bfbf56a080524.zip
fixes counting tags to be closed when a component can't be rendered (#490)
-rw-r--r--packages/astro/src/compiler/codegen/index.ts1
1 files changed, 1 insertions, 0 deletions
diff --git a/packages/astro/src/compiler/codegen/index.ts b/packages/astro/src/compiler/codegen/index.ts
index be0e1d17c..188029a2d 100644
--- a/packages/astro/src/compiler/codegen/index.ts
+++ b/packages/astro/src/compiler/codegen/index.ts
@@ -609,6 +609,7 @@ async function compileHtml(enterNode: TemplateNode, state: CodegenState, compile
paren++;
buffers[curr] += `h(${wrapper}, ${attributes ? generateAttributes(attributes) : 'null'}`;
} catch (err) {
+ paren--;
// handle errors in scope with filename
const rel = filename.replace(astroConfig.projectRoot.pathname, '');
// TODO: return actual codeframe here