Skip to content

Examples ​

The repository ships four runnable examples under examples/.

ExampleWhat it showsRun from the repo root
spaEvery plugin option, dynamic layouts and the common patternspnpm spa:dev
ssgStatic site generation with vite-ssg, layout from a router guardpnpm ssg:dev
client-sideClientSideLayout with every option setpnpm cli:dev
nested-routesNested routes, inheritDefaultLayout, setPageLayout on an inner layoutpnpm ner:dev

Each example also has :build and :preview scripts, for example pnpm spa:build and pnpm spa:preview.

Building the plugin first is required, since the examples consume dist/:

bash
pnpm install
pnpm build
pnpm spa:dev

Released under the MIT License.