Fireflies
Fireflies come out a few at a time and flash their slow conversation across your page, each flash leaving a short streak of light. Click to answer them, the way a female does from the grass, and the ones nearby turn and come to you.
Needs: None. A 2D canvas.
Customize
look
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| count | number | 90 | How many fireflies. They come out a few at a time. |
| look | "ascii" | "dither" | "dither" | Glyphs, or a dither of small square pixels. |
| cell | number | 4 | Size of one cell in px. Leave it unset for 4 with dither and 10 with ascii. |
| glow | string | "#c8ec5a" | The colour of their light. Deepened automatically on a light page so it still reads. |
| speed | number | 1 | Time scale. 0 holds the moment. |
| interactive | boolean | true | A click answers them. Read on the window, so content above keeps its clicks. |
| seed | number | 7 | Picks where each firefly starts and its rhythm. |
| opacity | number | 1 | Opacity of the whole swarm. |
| dpr | number | null | Device pixel ratio to render at. Math.min(devicePixelRatio, 2) when unset. |
| className | string | – | Class on the root element, which fills its parent. |
| style | CSSProperties | – | Style on the root element. |