concrete/bundles/build-failed
A placed section's renderer or one of its island chunks fails to bundle, so `build` could not write it.
A placed section's renderer or one of its island chunks fails to bundle, so build could not write it.
Graded by the bundles stage of concrete check, in the build venue. A violation reports this id and the file it failed at — see every rule and concrete check.
Reason
This stage bundles each placed section exactly as concrete build bundles it, so a
section that cannot be bundled here is a section the build could not have written either —
the failure simply arrives while you can still do something about it.
Publishing ships those bundles and nothing else:
there is no Node behind them, no workspace beside them, and nothing resolved at run time.
Fix
Read the message — it names the section and the bundler's own error. The usual causes are
a Node builtin imported into section code, a dependency that is not in package.json, and
a runtime require() the bundler cannot follow.
Before and after
import { readFileSync } from "node:fs";
import { Section, section, Slot, text } from "@homepages/concrete";
const disclaimer = readFileSync("./disclaimer.txt", "utf8");
export const Footer = section(
{ key: "footer", label: "Footer", slots: { tagline: text.short({ label: "Tagline" }) } },
({ slot }) => (
<Section as="footer">
<Slot.Text slot={slot.tagline} as="p" />
<small>{disclaimer}</small>
</Section>
),
);import { Section, section, Slot, text } from "@homepages/concrete";
export const Footer = section(
{
key: "footer",
label: "Footer",
slots: { tagline: text.short({ label: "Tagline" }), disclaimer: text.long({ label: "Disclaimer" }) },
},
({ slot }) => (
<Section as="footer">
<Slot.Text slot={slot.tagline} as="p" />
<Slot.Text slot={slot.disclaimer} as="small" multiline />
</Section>
),
);