Skip to content

Commit 2e15163

Browse files
committed
doh
1 parent 69f1ed8 commit 2e15163

File tree

1 file changed

+3
-2
lines changed
  • packages/svelte/src/compiler/phases/3-transform/client/visitors

1 file changed

+3
-2
lines changed

packages/svelte/src/compiler/phases/3-transform/client/visitors/ConstTag.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ export function ConstTag(node, context) {
1919
const init = build_expression(context, declaration.init, node.metadata.expression);
2020
let expression = create_derived(
2121
context.state,
22-
is_expression_async(init) ? b.arrow([], init, true) : b.thunk(init)
22+
is_expression_async(init) ? b.arrow([], init, true) : b.thunk(init),
23+
is_expression_async(init)
2324
);
2425

2526
if (dev) {
@@ -65,7 +66,7 @@ export function ConstTag(node, context) {
6566
is_expression_async(init)
6667
);
6768

68-
let expression = create_derived(context.state, fn);
69+
let expression = create_derived(context.state, fn, is_expression_async(init));
6970

7071
if (dev) {
7172
expression = b.call('$.tag', expression, b.literal('[@const]'));

0 commit comments

Comments
 (0)