File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed
packages/core/src/compiler Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ import vueJsxPlugin from '@vue/babel-plugin-jsx'
66import typescriptPlugin from '@babel/plugin-transform-typescript'
77import importMeta from '@babel/plugin-syntax-import-meta'
88import { parseJSXIdentifier } from '../utils'
9+ import { normalizePath } from 'vite'
910
1011const EXCLUDE_TAG = [ 'template' , 'script' , 'style' ]
1112const KEY_DATA = 'data-v-inspector'
@@ -19,7 +20,7 @@ export async function compileSFCTemplate(
1920 { code, id, type } : CompileSFCTemplateOptions ,
2021) {
2122 const s = new MagicString ( code )
22- const relativePath = path . relative ( process . cwd ( ) , id )
23+ const relativePath = normalizePath ( path . relative ( process . cwd ( ) , id ) )
2324 const result = await new Promise ( ( resolve ) => {
2425 switch ( type ) {
2526 case 'template' : {
You can’t perform that action at this time.
0 commit comments