Rive Instance
This code creates a new Rive animation, sets its properties, and starts playing it when it's loaded.
By Jeff McAvoy
Text Highlight Color
CSS code for high-contrast text selection: black background and white text.
By Jared Malan
Copy to Clipboard
Copy text to clipboard on button click with visual feedback and console log.
By Jared Malan
Number to Currency
Formats a string input as US dollar currency without decimal places.
By Jared Malan
Fix Paragraph Runts With Nonbreaking Space
Prevent single-word runts in HTML elements with the class `.no-runt`.
By Corey Moen
Refresh after form submit
Automatically refreshes the page 7 seconds after any form submission.
By Corey Moen
Pointer events
CSS classes to control pointer events: .pointer-events-off disables interactions, .pointer-events-on enables interactions.
By Jared Malan
Set localStorage
Store an array of surfer names in localStorage as a JSON string.
By Jared Malan
GSAP card staggered animation
Animate elements on viewport entry with GSAP and ScrollTrigger.
By Digipop
Validation - Website
Validates URLs using regex and handles validation on input blur.
By Jared Malan
Track User Localstorage
Tracks user navigation and populates a form field with the history.
By Jared Malan
Richtext Reset
Removes top margin of the first and bottom margin of the last child elements in a rich text container.
By Jared Malan
Handle Resize
Optimizes window resize handling by debouncing rerendering of elements.
By Jared Malan
Improved Font Rendering
CSS for font smoothing, text rendering, and scroll behavior on the body element.
By Jared Malan
Rive Input - Update Boolean
Set a boolean Rive input to true or false
By Jeff McAvoy
Rive Input - Update Number
This code lets you update the value of a Rive number input variable.
By Jeff McAvoy
Auto update copyright year
Dynamically updates an HTML element to display the current year using JavaScript.
By Digipop
Copy to Clipboard
Copy text to clipboard on button click with visual feedback and console log.
By Jared Malan