Brian's public fiddles
-
2Lx9n6ru
No-Library (pure JS), HTML, CSS, JavaScript
-
Async Await Test
Just playing around with async and await.
-
Flash Yellow
Color flash when adding a class.
-
One Flatpickr for Multiple Inputs
Rather than rendering a bunch or calendars to the DOM, I'm creating a Flatpickr instance on demand and destroying it so There Can Be Only One.
-
Flash Yellow
Color flash when adding a class.
-
Promise chain
Just playing around with how promises work in vanilla JavaScript.
-
Coords from Distance and Angle
For finding how far away something should be when it's off at some funny angle.
-
jQuery Deferred Example
Using an array of sources and resolving a Deferred for each one and then doing stuff when they're all resolved.
-
Get deep properties dynamically
This is meant for use with Underscore's "groupBy" method, when you're using an iterator function to sort by a deeper property.
-
SpectrumJS Example
Just playing around with it, and throttling the move event.
-
jQuery UI Custom Autocomplete
_renderItemData is internal, and you don't want to override it. You don't even want to encounter it, really. This custom widget avoids that trouble.
-
Wait for All Deferreds to Resolve
Doing some stuff when each Deferred Object resolves, and doing some other stuff only when ALL of them have resolved.
-
Height of a div's contents.
Get the height of the content inside the content container.
-
Run JS at the end of a CSS3 transition
Identifying the browser's event for the end of a CSS transition, and tossing that into a jQuery listener.
-
Center images without knowing their sizes
Due to a weird situation at work (caused by the Marketing Department) I have to do this clunky thing to get images centered with CSS alone.
-
AngularJS with Two Data Sources
Telling AngularJS to wait up while multiple data sources come in.
-
Show and Hide Content
Sort of like tabs, but independent of markup. Shows corresponding content when a link is clicked.
-
!This is !important!
Checking out specificity and how !important things can be. EVEN YOU can override an inline style!
-
Pipes betwen list items
Neat CSS selector that Alyssa Nicoll posted on Twitter.
-
jQuery draggable with limits
Responsive horizontal nav menu that only drags to its edges. Still not totally happy with the right side. Might round off the list items to keep fractions out of the mix.