Skip to content

Commit f86eb2a

Browse files
authored
Merge pull request #12 from vain0x/fix-pathsep
2 parents 7d512ca + 9df7057 commit f86eb2a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/lib/import.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,9 @@ function getModuleSpceifier(selfPath: string, modulePath: string, project: ts.se
114114

115115
let specifier: string;
116116
if (compilerOptions.baseUrl) {
117-
specifier = path.relative(compilerOptions.baseUrl, modulePath);
117+
specifier = path.posix.relative(compilerOptions.baseUrl, modulePath);
118118
} else {
119-
specifier = './' + path.relative(path.dirname(selfPath), modulePath);
119+
specifier = './' + path.posix.relative(path.dirname(selfPath), modulePath);
120120
}
121121

122122
return getFilePathWithoutExt(specifier);

0 commit comments

Comments
 (0)