Skip to content

Commit

Permalink
fix: Prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
clansty committed Oct 9, 2024
1 parent 3d64038 commit 8e7047e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ export function inlineEvalManifest(code: string, config: Config): string {
console.log("# inlineEvalManifest");
const manifestJss = globSync(
path.join(config.paths.standaloneAppDotNext, "**", "*_client-reference-manifest.js").replaceAll("\\", "/")
).map((file) => file.replaceAll("\\", "/").replace(`${config.paths.standaloneApp.replaceAll("\\", "/")}/`, ""));
).map((file) =>
file.replaceAll("\\", "/").replace(`${config.paths.standaloneApp.replaceAll("\\", "/")}/`, "")
);
return code.replace(
/function evalManifest\((.+?), .+?\) {/,
`$&
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,10 @@ export function patchReadFile(code: string, config: Config): string {
// Same as above, the next-server code loads the manifests with `readFileSync` and we want to avoid that
// (source: https://github.com/vercel/next.js/blob/15aeb92e/packages/next/src/server/load-manifest.ts#L34-L56)
// Note: we could/should probably just patch readFileSync here or something!
const manifestJsons = globSync(path.join(config.paths.standaloneAppDotNext, "**", "*-manifest.json").replaceAll("\\", "/")).map(
(file) => file.replaceAll("\\", "/").replace(config.paths.standaloneApp.replaceAll("\\", "/") + "/", "")
const manifestJsons = globSync(
path.join(config.paths.standaloneAppDotNext, "**", "*-manifest.json").replaceAll("\\", "/")
).map((file) =>
file.replaceAll("\\", "/").replace(config.paths.standaloneApp.replaceAll("\\", "/") + "/", "")
);
code = code.replace(
/function loadManifest\((.+?), .+?\) {/,
Expand Down

0 comments on commit 8e7047e

Please sign in to comment.