Skip to content

Commit

Permalink
small tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
ryansolid committed Jul 19, 2024
1 parent d86ab61 commit 98d129e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/start/src/server/StartServer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,11 @@ export function StartServer(props: { document: Component<DocumentComponentProps>
while (matches.length && (!matches[0].info || !matches[0].info.filesystem)) matches.shift();
const matched = matches.length && matchRoute(matches, context.routes);
if (matched) {
const inputs = import.meta.env.MANIFEST[import.meta.env.START_ISLANDS ? "ssr" : "client"]!
.inputs
for (let i = 0; i < matched.length; i++) {
const segment = matched[i];
const part = import.meta.env.MANIFEST[import.meta.env.START_ISLANDS ? "ssr" : "client"]!
.inputs[segment["$component"].src]!;
const part = inputs[segment["$component"].src]!;
assetPromises.push(part.assets() as any);
}
} else if (import.meta.env.DEV) console.warn("No route matched for preloading js assets");
Expand Down

0 comments on commit 98d129e

Please sign in to comment.