print
ComputerGuy 3 months ago
parent 566da5b95f
commit 0b9f5607c6

@ -16,7 +16,7 @@ export function print(ast) {
});
}
/** @type {Visitors<AST.SvelteNode | AST.CSS.Node, any>} */
/** @type {Visitors<AST.SvelteNode, any>} */
const visitors = {
Root(node, context) {
if (node.options) {
@ -354,6 +354,14 @@ const visitors = {
}
},
KeyBlock(node, context) {
context.write('{#key ');
context.visit(node.expression);
context.write('}');
context.visit(node.fragment);
context.write('{/key}');
},
LetDirective(node, context) {
context.write(`let:${node.name}`);
if (

Loading…
Cancel
Save