1.0.0 β’ Published 7 years ago
fancy-button v1.0.0
fancy-button
Glitch Button with sprinkles added on top β¨
Uses lit-html, haunted, and rollup.js
π Hey!
This project is experimental. It doesn't work in Edge and IE.
π€ How to Use
π¦ Install via NPM
Add fancy-button package to your package.json
Import it
import 'fancy-button';Include the component!
<glitch-button top-right></glitch-button>π Script Tag
Include this in your head tag:
<script src="https://unpkg.com/fancy-button" defer></script>Include in the end of your body tag:
<glitch-button top-right></glitch-button>π Available Attributes
top-rightplaces the button in top right corner.theme="glitch"loads Glitch stylesheet.
β
Why better-button?
| button | better-button | |
|---|---|---|
| Lighter | π 45.8 KB total (including images and styles) | β‘ 7.9 KB (brotli) |
| Encapsulated | π Your styles can mess with the button | π Safe to use in any page |
| Cached | β³ Doesnβt use cache | β± Cache enabled |
| Accessible | β Could be more accessible | β€ Everyone can play! |