Skip to content
HomePagesHomePages template kit
Menu

template-kit/bundle-incomplete

The template-kit/bundle-incomplete authoring rule — what it enforces, why, and how to fix it.

A section folder is yours. Its only structural requirement is that four contract files exist at its root.

A section folder must contain these four, as files, at the folder root:

File Declares
schema.ts the slots and options the section has
fill-spec.ts how AI fills those slots
fixtures.ts sample content for local preview
Renderer.tsx the markup

Each missing file is one violation, so a folder holding only a Renderer.tsx reports three times.

Two near-misses do not satisfy it:

  • a directory named schema.ts/ — the check wants a file;
  • a file at components/schema.ts — the four are looked for at the folder root, not searched for down the tree.

Everything else in the folder is unconstrained. components/, hooks/, utils/, any nesting, any number of support modules, islands, stylesheets: the check has no opinion about them, and neither does the rest of the kit.

The four files are the platform’s entire interface to a section. The publisher reads schema.ts to know what the section contains, the fill pipeline reads fill-spec.ts to fill it, preview reads fixtures.ts, and Renderer.tsx is the markup. A folder missing one of them cannot be loaded as a section.

That freedom has one non-obvious consequence, worth knowing before it surprises you: every file in the folder is part of the section’s identity. The content hash covers the whole folder, not just the four — so editing a helper, a util, or even a comment produces a new section version on the next publish, exactly as editing Renderer.tsx would.

Create the missing file at the folder root. A section that fills nothing still needs a fill-spec.ts; a section with no designed states still needs a fixtures.ts. Declaring “nothing to fill” is a declaration.

sections/hero/
Renderer.tsx
schema.ts
components/
Headline.tsx

Two violations: fill-spec.ts and fixtures.ts are missing. components/ is not one of them — it was never a problem.

sections/hero/
Renderer.tsx
schema.ts
fill-spec.ts ← added
fixtures.ts ← added
components/
Headline.tsx
sections/hero/fill-spec.ts
import type { FillSpecShape } from "@homepages/template-kit";
export const fillSpec = {
reads: [],
decisions: [
{
id: "headline_text",
type: "text-block",
produces: ["headline"],
length_cap: 60,
structure: "single_sentence",
voice_prompt: "Confident premium-listing voice. Title Case.",
},
],
} as const satisfies FillSpecShape;
sections/hero/fixtures.ts
import type { FixtureModule } from "@homepages/template-kit";
const fixtures: FixtureModule = {
base: {
slots: { headline: "A mansard Victorian in the heart of Jamaica Plain" },
},
};
export default fixtures;
  • The schema system — what each of the four files declares, and the types they satisfy.
  • missing-slot-marker — the check that runs once the four exist: every editable slot in schema.ts has a marker in the JSX.