Skip to content

Commit

Permalink
fix: windows issue in dts redirect (#746)
Browse files Browse the repository at this point in the history
  • Loading branch information
Timeless0911 authored Feb 11, 2025
1 parent d16af1d commit 676cad1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/plugin-dts/src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,8 @@ export async function redirectDtsImports(
let redirectImportPath = importPath;

if (absoluteImportPath && redirect.path) {
const isOutsideRootdir = !absoluteImportPath.startsWith(
rootDir + path.sep,
const isOutsideRootdir = !normalize(absoluteImportPath).startsWith(
normalize(rootDir) + path.sep,
);

if (isOutsideRootdir) {
Expand Down

0 comments on commit 676cad1

Please sign in to comment.