Skip to content

Commit

Permalink
fix: incorrect compiler address resolution (#133)
Browse files Browse the repository at this point in the history
Co-authored-by: luolei <luolei@kuaishou.com>
  • Loading branch information
rorry121 and luolei committed Oct 28, 2022
1 parent c6d07d7 commit 01cc125
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/compile.ts
Expand Up @@ -20,7 +20,11 @@ function requireCompiler() {
if (compileRoot) {
try {
compiler = _require(_require.resolve('vue/compiler-sfc', { paths: [compileRoot] }))
} catch (e) {}
} catch (e) {
try {
compiler = _require(_require.resolve('@vue/compiler-sfc', { paths: [compileRoot] }))
} catch (e) {}
}
}

if (!compiler) {
Expand Down

0 comments on commit 01cc125

Please sign in to comment.