Diorama

Made for a big screen.

This site is one 3D scene, built for a computer: a wide window and a mouse. Open dioramajs.dev on a desktop or a laptop to see it.This site is one 3D scene, built for a wide window. Make this one wider, or open dioramajs.dev on a larger screen.

GitHub

DioramaDocs

DioramaAstroOptions interface

Options of the Astro integration.

View as Markdown
import type { DioramaAstroOptions } from '@dioramajs/diorama/astro'
interface DioramaAstroOptions extends DioramaPluginOptions

Members

NameTypeDescription
readonly dir?string

The effects folder, relative to the Vite root. Default 'src/effects'.

readonly lenis?boolean | AstroLenisOptions

Smooth scroll with Lenis on every page: true or Lenis options. The site installs lenis. The app of start() drives it, and it keeps the scroll ClientRouter sets on a page change.

readonly restoreScroll?'history' | ScrollRestore

Which ClientRouter links land where the reader left the page instead of at the top. 'history' (default), as browsers do: only Back and Forward. 'parents': also links up the address, to / from anywhere or to /work from /work/aurora, so a list opens where it was left while a project opened from it starts at the top. 'visited': links to any page seen earlier in the tab. A link with a #hash still goes to its anchor.

readonly types?string | false

The types file, relative to the root, or false for none. Default 'src/diorama.gen.d.ts'.

Defined in packages/diorama/src/astro.ts.