# HTML pages with layouts and React islands
Status: Proposed
This is a forward-looking proposal, not a feature of the current release. The current route formats remain `page.tsx` and `page.md`; do not describe `page.html` as implemented until the acceptance criteria below are met.
## Decision
Keep `page.tsx` as Nib's primary component-bearing template format. If Nib adds
`page.html`, use standards-conforming HTML fragments for markup and an optional
typed `page.config.ts` companion for metadata, a React layout, and island
bindings.
Do not add import statements, JSX expressions, component props, or hydration
directives to HTML. A page places a bound island with one reserved custom
element:
```html
```
The companion TypeScript file imports the React values and supplies typed props:
```ts
import { bindIsland, defineHtmlPage } from '@briansunter/nib/html'
import Counter from '../../islands/counter'
import DocsLayout from '../../layouts/docs'
export default defineHtmlPage({
meta: {
title: 'Counter',
description: 'A counter embedded in a static HTML page.',
},
layout: DocsLayout,
islands: {
counter: bindIsland(Counter, {
props: { initialCount: 0 },
hydrate: 'visible',
}),
},
})
```
This is the cleanest HTML option, but it is intentionally less direct than
TSX. Use it for imported, generated, or markup-first content. Use TSX when a
page composes several React modules or derives props in code.
## Why HTML cannot cleanly import React components
HTML can load a JavaScript module with `