Skip to content

Commit db608b5

Browse files
committed
fix(compiler-sfc): missing keywords of method property
1 parent f67bb50 commit db608b5

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/compiler-sfc/src/compileScript.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -790,7 +790,9 @@ export function compileScript(
790790
prop.value.end!
791791
)}`
792792
} else {
793-
defaultString = `default() ${scriptSetupSource.slice(
793+
defaultString = `${prop.async ? 'async ' : ''}${
794+
prop.kind !== 'method' ? `${prop.kind} ` : ''
795+
}default() ${scriptSetupSource.slice(
794796
prop.body.start!,
795797
prop.body.end!
796798
)}`

0 commit comments

Comments
 (0)