Delicious

Delicious

10528 bookmarks
Custom sorting
Scroll to anchor with offset when coming from another page
Scroll to anchor with offset when coming from another page
Hi there, Thanks for writing in. That code is for links that directly clicked but not for the page that is loaded. You'll need to add another set of code like this jQuery ( document ).ready ( function($) { var hash= window.location.hash if ( hash == '' || hash == '#' || hash == undefined ) return false; var target = $(hash); headerHeight = 120; target = target.length ? target : $('[name=' + this.hash.slice(1) +']'); if (target.length) { ...
·theme.co·
Scroll to anchor with offset when coming from another page
Smooth Scrolling
Smooth Scrolling
Native browser smooth scrolling is like this: // Scroll to specific values // scrollTo is the same window.scroll({ top: 2500, left: 0, behavior: 'smooth'
·css-tricks.com·
Smooth Scrolling
LazyLoad (vanilla-lazyload)
LazyLoad (vanilla-lazyload)
LazyLoad is a fast, lightweight and flexible script that speeds up your web application by loading images only as they enter the viewport. LazyLoad supports responsive images.
·andreaverlicchi.eu·
LazyLoad (vanilla-lazyload)
Solved with CSS! Dropdown Menus | CSS-Tricks
Solved with CSS! Dropdown Menus | CSS-Tricks
A common UI pattern that we see on the web are dropdown menus. They’re used to display related information in pieces, without overwhelming the user with buttons, text, and options. Somewhere that we see these a lot is inside of headers or navigation areas on websites. Let’s see if we can make one of these menus with CSS alone.
·css-tricks.com·
Solved with CSS! Dropdown Menus | CSS-Tricks
Solved with CSS! Logical Styling Based on the Number of Given Elements | CSS-Tricks
Solved with CSS! Logical Styling Based on the Number of Given Elements | CSS-Tricks
Did you know that CSS is Turing complete? Did you know that you can use it to do some pretty serious logical styling? Well you can! You don’t have to set all of your logic-based styling rules in JavaScript, or even have to use JavaScript to set classes you are styling against. In many cases, CSS can handle that itself. I’m still discovering new CSS tricks everyday, and it just makes me love it even more.
·css-tricks.com·
Solved with CSS! Logical Styling Based on the Number of Given Elements | CSS-Tricks
Using Multi-Step Animations and Transitions
Using Multi-Step Animations and Transitions
CSS animations are rad and the concept is fairly simple. Name the animation, define the movement in @keyframes and then call that animation on an element.
·css-tricks.com·
Using Multi-Step Animations and Transitions
oncebot/pushbar.js
oncebot/pushbar.js
pushbar.js - Tiny javascript plugin for creating sliding drawers in web apps
·github.com·
oncebot/pushbar.js
Building A Static Site With Components Using Nunjucks
Building A Static Site With Components Using Nunjucks
Even if you don’t use any client-side JavaScript at all to build a site, it doesn’t mean you have to give up on the idea of building with components. Learn how to build a static site with the help of …
·smashingmagazine.com·
Building A Static Site With Components Using Nunjucks
Four Killer Features of Nunjucks
Four Killer Features of Nunjucks
Nunjucks calls itself "A rich and powerful templating language for JavaScript", which sounds about right. It's not intentionally super lightweight like
·css-tricks.com·
Four Killer Features of Nunjucks
DIY Talc-Free Baby Powder
DIY Talc-Free Baby Powder
My book publisher forwarded some interview questions to me from a British magazine a while back. One of the questions was, "Why would people want to make their own body care products instead of buying
·nwedible.com·
DIY Talc-Free Baby Powder
Lazy loading images using Intersection Observer
Lazy loading images using Intersection Observer
If you haven’t had the chance to watch it yet, Paul Lewis put together an awesome video series that demonstrates how to build a media player alongside some of the great features of Progressive Web App…
·deanhume.com·
Lazy loading images using Intersection Observer
RegEx to match stuff between parentheses
RegEx to match stuff between parentheses
I'm having a tough time getting this to work. I have a string like: something/([0-9])/([a-z]) And I need regex or a method of getting each match between the parentheses and return an array of mat...
·stackoverflow.com·
RegEx to match stuff between parentheses
Uninstall all installed gems, in OSX?
Uninstall all installed gems, in OSX?
There are instances where I would like to revert and uninstall all previous gem installations. For instance, I needed to assist a friend migrate their rails development machine to use RVM. As the...
·stackoverflow.com·
Uninstall all installed gems, in OSX?
Install Ruby Gems on Mac OS X without sudo
Install Ruby Gems on Mac OS X without sudo
I have never had a default installation of Ruby gems on Mac OS X let me simplyinstall new gems without requiring sudo. If you would like to install Ruby gems...
·michaelehead.com·
Install Ruby Gems on Mac OS X without sudo
How to uninstall all ruby gems in one line
How to uninstall all ruby gems in one line
Update: whilst this post is still useful, I now recommend that people use rvm to manage their gems, which makes the following post redundant as rvm allows you to quickly and easily delete gemsets at w…
·jamespmcgrath.com·
How to uninstall all ruby gems in one line
Headings with Side Lines
Headings with Side Lines
Fun with heading elements and pseudo-element side lines in Sass....
·codepen.io·
Headings with Side Lines
Ruby University: Install Ruby on macOS with Rbenv
Ruby University: Install Ruby on macOS with Rbenv
This video teaches you how to install the latest version of Ruby on your macOS computer. Using a tool called rbenv makes installing the latest (and multiple)...
·youtube.com·
Ruby University: Install Ruby on macOS with Rbenv