From 88a8f7d4bf12626174c5875a3be50013cd980791 Mon Sep 17 00:00:00 2001 From: Romain Lenzotti Date: Sat, 27 Apr 2024 18:40:11 +0200 Subject: [PATCH] fix(swagger): fix resolved swagger ui asset path for ESM version Closes: #2683 --- packages/specs/swagger/scripts/constants.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/specs/swagger/scripts/constants.js b/packages/specs/swagger/scripts/constants.js index 01970f2321e..4ed61e8221f 100644 --- a/packages/specs/swagger/scripts/constants.js +++ b/packages/specs/swagger/scripts/constants.js @@ -2,6 +2,6 @@ import {dirname} from "node:path"; import {fileURLToPath} from "node:url"; // @ts-ignore -export const SWAGGER_UI_DIST = dirname(import.meta.resolve("swagger-ui-dist")); +export const SWAGGER_UI_DIST = dirname(import.meta.resolve("swagger-ui-dist")).replace("file://", ""); // @ts-expect-error export const ROOT_DIR = dirname(fileURLToPath(import.meta.url));