One GPU device per page
All the backgrounds on a page share one GPU device. They stop drawing when they scroll out of view or the tab is hidden.
Beautiful backgrounds that move with you.
pnpm add @goatsoft/aurora @goatsoft/aurora-vue
Layers
Parameters
CurtainHow it works
All the backgrounds on a page share one GPU device. They stop drawing when they scroll out of view or the tab is hidden.
Each background also has a CSS gradient that approximates it. Browsers without WebGPU show the gradient.
Colours blend in OKLab, so a gradient between two bright colours stays bright in the middle.
Generators
Try the backgrounds below, or combine them in Studio.
Workflow
Open Aurora Studio, start from a scene or a blank canvas, and save a .aurora file. The file is plain JSON.
The bundler plugin checks the file when you build, reports mistakes with a line and column, and gives the import a type.
Use the Vue component or the custom element.
<script setup lang="ts">
import { AuroraBackground } from '@goatsoft/aurora-vue'
import hero from './hero.aurora' // validated and typed at build time
</script>
<template>
<section class="relative">
<AuroraBackground :src="hero" />
<h1>Your headline</h1>
</section>
</template>
<script type="module">
import '@goatsoft/aurora/element'
</script>
<section style="position: relative">
<aurora-bg src="/hero.aurora"></aurora-bg>
<h1>Your headline</h1>
</section>
import aurora from '@goatsoft/aurora-unplugin/vite'
import vue from '@vitejs/plugin-vue'
import { defineConfig } from 'vite'
export default defineConfig({
plugins: [vue(), aurora()],
})
The editor
Adjust layers, colours and motion. Save a .aurora file for your site.
Open Aurora StudioLayers
Parameters
CloudsScenes
Studio includes multi-layer scenes and a starter file for every generator. Open one and change it.