A JavaScript library that hides spoilers on web pages using SVG blur effects, revealing content on hover and click.
SPOILER ALERT! is a JavaScript library that helps website owners hide spoiler content using SVG blur effects. It solves the problem of accidentally revealing plot points or sensitive information by blurring text and images, which users can then reveal through hover and click interactions.
Website owners, bloggers, and content publishers who share spoiler-prone content like movie reviews, book analyses, or game walkthroughs.
Developers choose SPOILER ALERT! because it's lightweight, easy to implement, and provides an elegant visual solution to spoiler management without requiring complex CSS or framework dependencies.
SPOILER ALERT! A happy little bit of javascript to hide spoilers on your site.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Simply include spoiler.js and call a function with CSS selectors, as shown in the README with spoilerAlert('spoiler, .spoiler'), making setup quick with minimal code.
Configuration options allow setting maximum and partial blur levels, demonstrated in the README with {max: 10, partial: 4}, giving control over visual hiding.
Tested and works in Chrome, Safari, Firefox, and Mobile Safari, ensuring broad compatibility for most modern web environments.
Uses SVG blur filters to hide content in a visually appealing way, enhancing user experience over plain text hiding or basic CSS methods.
Only supports mouseover and click interactions; lacks keyboard navigation, touch gestures beyond click, or other advanced user controls for accessibility.
Revealed content remains visible without a way to re-hide spoilers or save user preferences across sessions, limiting usability for repeat visitors.
Customization is restricted to blur levels; no options for colors, animation speed, or other stylistic elements, as admitted by the minimal configuration.