Skip to content

Instantly share code, notes, and snippets.

View wiljanslofstra's full-sized avatar

Wiljan Slofstra wiljanslofstra

View GitHub Profile
@stidges
stidges / tailwind.itermcolors
Last active November 30, 2023 21:00
An iTerm2 color scheme based on the Tailwind CSS color scheme (https://tailwindcss.com/docs/colors)
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Ansi 0 Color</key>
<dict>
<key>Alpha Component</key>
<real>1</real>
<key>Blue Component</key>
<real>0.17254902422428131</real>
@mrmartineau
mrmartineau / stimulus.md
Last active April 19, 2024 09:41
Stimulus cheatsheet
@tabrindle
tabrindle / webp-convert-directory.sh
Last active April 30, 2024 14:03
Convert all files in directory to webp, with default params, or standard cwebp params passed from command
#!/bin/bash
PARAMS=('-m 6 -q 70 -mt -af -progress')
if [ $# -ne 0 ]; then
PARAMS=$@;
fi
cd $(pwd)
@simonsmith
simonsmith / amd-jquery-plugin.js
Last active April 29, 2020 15:28
AMD compatible plugin for jQuery
// UMD dance - https://github.com/umdjs/umd
!function(root, factory) {
if (typeof define === 'function' && define.amd) {
define(['jquery'], factory);
} else {
factory(root.jQuery);
}
}(this, function($) {
'use strict';
@rvr
rvr / 2x-mixin.scss
Created October 11, 2012 18:25
Hi res image mixin
div {
@include image-2x("logo.png", "logo2x.png");
}
@mixin image-2x($image1, $image2) {
background-image: url($image);
@media (…) {
background-image: url($image2);
background-size: image-width($image1) image-height($image1);
}