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

EFFECT_UNKNOWN

Package @dioramajs/diorama/effects Level warning

Markup or code names an effect that is not registered, so the element stays plain DOM.

View as Markdown
On this page
EFFECT_UNKNOWN: unknown effect "{name}"; known: {names}

Why it happens

  • The name in data-dio has a typo. The warning lists every registered name after known:.
  • The effect file is missing from the effects folder (src/effects/ with the build plugin), or the effect lives elsewhere and is not passed to start({ effects }).
  • The token is not a valid effect name. Names are kebab-case and cannot be a reserved attribute name such as key or load. The message then reads "{token}" is not an effect name, and the token is ignored.

An unknown name prints once per name, after the engine has loaded, because the name can still arrive later. Until then the element waits without data-dio-state, and it picks up the effect as soon as an entry with that name is registered.

How to fix

Check the token against the list in the message:

<img src="/img/cover.avif" data-dio="rippel" />
<img src="/img/cover.avif" data-dio="ripple" />

For an effect outside the effects folder, register it by name:

import { start } from '@dioramajs/diorama'
export const app = start({
effects: { brighten: () => import('./brighten') },
})