Skip to content

Commit 2bb44b9

Browse files
rtk-query-codegen-openap: Fixed relative apiFile path when generating on Windows (#1972)
1 parent b678c9b commit 2bb44b9

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

packages/rtk-query-codegen-openapi/src/generate.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ export async function generateApi(
102102
outputFile = path.resolve(process.cwd(), outputFile);
103103
if (apiFile.startsWith('.')) {
104104
apiFile = path.relative(path.dirname(outputFile), apiFile);
105+
apiFile = apiFile.replace(/\\/g, '/')
105106
if (!apiFile.startsWith('.')) apiFile = './' + apiFile;
106107
}
107108
}

0 commit comments

Comments
 (0)