Stimuli ⚡️
Collection of useful single-responsibility Stimulus controllers.
Work in progress. Needs proper tests.
Installation
npm install stimuli
Usage
Import and register the desired controllers with your application.
const application = Applicationstartapplication
Controllers
Autoplay
Autoplay video or audio files. Retries with a muted version of the video if it failes on first try.
Measure
Measure the deimensions of an element and stores the value in a CSS custom property.