A beautiful ASCII art animation library with customizable noise patterns and effects.
🎬 View Live Demo on GitHub Pages
- 🌊 Fluid ASCII art animations using noise patterns
- 🎨 Customizable color palettes and visual effects
- ⚡ High-performance Canvas-based rendering
- 📱 Responsive design with mobile support
- ♿ Accessibility features (respects
prefers-reduced-motion
) - 🎛️ Runtime configuration options
- 📦 Zero dependencies
<canvas id="ascii-canvas"></canvas>
<script src="./index.js"></script>
<script>
const canvas = document.getElementById('ascii-canvas')
const asciiField = new AsciiField(canvas)
asciiField.start()
</script>
<canvas id="ascii-canvas"></canvas>
<script src="./index.js"></script>
<script>
const canvas = document.getElementById('ascii-canvas')
const asciiField = new AsciiField(canvas, {
bg: '#000000',
fg: '#00ff00',
palette: ' .:-=+*#%@',
speed: 0.02,
fontPx: 14,
})
asciiField.start()
</script>
new AsciiField(canvas: HTMLCanvasElement, options?: Partial<AsciiFieldOptions>)
start()
- Start the animation loopstop()
- Stop the animation loopdestroy()
- Clean up and destroy the instanceupdate(options: Partial<AsciiFieldOptions>)
- Update options at runtimeresize()
- Force resize (useful when container size changes)
npm install asciidance
# Install dependencies
npm install
# Build the library
npm run build
# Run in development mode
npm run dev
# Run tests
npm test
This repository is configured for automatic deployment to GitHub Pages:
- The
index.html
file in the root serves as the GitHub Pages entry point - GitHub Actions automatically builds and deploys on every push to
main
- The live demo is available at: https://cbiering.github.io/asciidance
MIT