release: WRNexusJS 0.4.0
This commit is contained in:
1 parent
8b728a3e5d
commit
30e5721e84
250 files changed
+10065
-3923
No files matched your search
@@ -62,6 +62,8 @@ export async function bundleCss(entryPath: string, mode: Mode): Promise<string>
|
||||
if (!result.success) {
|
||||
throw new Error("CSS bundle failed:\n" + result.logs.map(String).join("\n"));
|
||||
}
|
||||
const cssOutput = result.outputs.find((o) => o.path.endsWith(".css")) ?? result.outputs[0];
|
||||
return await cssOutput!.text();
|
||||
const cssOutput =
|
||||
result.outputs.find((output) => output.path?.endsWith(".css")) ?? result.outputs[0];
|
||||
if (!cssOutput) throw new Error("CSS bundle produced no output.");
|
||||
return await cssOutput.text();
|
||||
}
|
||||
Reference in new issue
Block a user