Skip to content

Commit

Permalink
fixes #52
Browse files Browse the repository at this point in the history
  • Loading branch information
michael-spengler committed Mar 4, 2022
1 parent 6309290 commit e982798
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions src/cli/prepare.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,13 +67,14 @@ export async function Dist() {
? join("dist", "index.html")
: join("dist", basename(output));

// normalize path ./example to /example
if (!output.endsWith(".html")) {
transform.push({
target: `="./${basename(output)}"`,
replacer: `="/${basename(output)}"`,
});
}
// Commenting the following lines to fix https://github.com/crewdevio/Snel/issues/52
// // normalize path ./example to /example
// if (!output.endsWith(".html")) {
// transform.push({
// target: `="./${basename(output)}"`,
// replacer: `="/${basename(output)}"`,
// });
// }

if (output.endsWith("index.html")) {
source = (source as string).replace(`<base href="/deps/">`, "");
Expand Down

0 comments on commit e982798

Please sign in to comment.