Skip to content

Commit abe72f8

Browse files
author
Artur Tagisow
committed
Fix @/abc being treated as scoped module
Fixes #1851 Before this commit, @/abc was being wrongly detected as a scoped module. This was a problem when somebody had a webpack alias `@`. (eg. @ -> ./src) In general, scoped modules can't start with @/, I think they have to be like @/abcd.
1 parent 843055c commit abe72f8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/core/importType.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ function typeTest(name, settings, path) {
9393
}
9494

9595
export function isScopedModule(name) {
96-
return name.indexOf('@') === 0
96+
return name.indexOf('@') === 0 && !name.startsWith('@/')
9797
}
9898

9999
export default function resolveImportType(name, context) {

0 commit comments

Comments
 (0)