@quillstone/theme
layouts
css
fields.json
images
modules
hero.module
pricing.module
nav.module
footer.module
templates
about.page.html
blog.index.html
blog.post.html
home.page.html
partials
// modules/menu-section.js
const section = defineModule({
label: "Menu section",
fields: [
{ name: "heading", type: "text" },
{ name: "items", type: "repeater" }
]
});
export function render(ctx) {
const root = document.createElement("section");
root.className = "qs-menu";
for (const item of ctx.items) {
const row = tag("article", "qs-menu__row");
row.append(
tag("h3", "qs-menu__title", item.title),
tag("p", "qs-menu__body", item.body)
);
root.append(row);
}
return root;
}
// hydrate on the client only when visible
section.hydrate("visible");
Menu section
Headingedit
Style set2
Filter tagslearn
Repeater6 items
Cacheedge