Handle Resize
Optimizes window resize handling by debouncing rerendering of elements.
By Jared Malan
Fetch - Get
A JavaScript code snippet that fetches data from a URL, converts the response to JSON, and logs the data or any error to the console.
By Jared Malan
Filter Out Selection
Filter array elements matching button text on button click.
By Jared Malan
Fetch - Put
Update server resource via PUT request using Fetch API.
By Jared Malan
GSAP card staggered animation
Animate elements on viewport entry with GSAP and ScrollTrigger.
By Digipop
Number to Currency
Formats a string input as US dollar currency without decimal places.
By Jared Malan
Fetch - Post
This code sends a POST request with JSON data to a specific URL, processes the JSON response, and handles any errors.
By Jared Malan
Load All CMS Items
This JavaScript code parses and displays CMS items from a webpage, storing them in an array and rendering them in a specified div.
By Jared Malan
Set Hidden Input Value From URL Parameters
Retrieve URL parameter and set it to a hidden input field.
By Corey Moen
Animated American Flag
Render and animate an American flag on a canvas with dynamic waving effects.
By Jared Malan
Progress Bar Timer
JavaScript code to dynamically update a progress bar based on time between two dates.
By Digipop
Validation - Website
Validates URLs using regex and handles validation on input blur.
By Jared Malan
Text Highlight Color
CSS code for high-contrast text selection: black background and white text.
By Jared Malan
Rive Input - Create Variable by Name
Create a variable for your state machine inputs by input name.
By Jeff McAvoy
Validation - Email
Validates email format and handles invalid input on blur event.
By Jared Malan
Validation - LinkedIn URL
Validate LinkedIn URLs and handle input validation on blur event.
By Jared Malan
Pointer events
CSS classes to control pointer events: .pointer-events-off disables interactions, .pointer-events-on enables interactions.
By Jared Malan
Rive Input - Update Number
This code lets you update the value of a Rive number input variable.
By Jeff McAvoy