Skip to content

Commit 2d29042

Browse files
committed
fix: backward compatibility
1 parent fc540f5 commit 2d29042

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/context.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,8 @@ export class Context {
187187
}
188188

189189
normalizePath(path: string) {
190-
return resolveAlias(path, this.viteConfig?.resolve.alias || [])
190+
// @ts-expect-error backward compatibility
191+
return resolveAlias(path, this.viteConfig?.resolve?.alias || this.viteConfig?.alias || [])
191192
}
192193

193194
relative(path: string) {

0 commit comments

Comments
 (0)