Skip to content

Instantly share code, notes, and snippets.

View Santoshah's full-sized avatar
🏠
Working from home

Santosh Santoshah

🏠
Working from home
View GitHub Profile
@Santoshah
Santoshah / filter-by-iteratee.js
Created May 14, 2018 13:11 — forked from nickells/filter-by-iteratee.js
Transpiled FilterByIteratee
"use strict";
// Function definition
var filterByIteratee = function filterByIteratee(array, iteratee) {
// Empty object to store attributes as we encounter them
var previousAttributeNames = {};
return array.filter(function (item) {
// Get the right value
@Santoshah
Santoshah / contents.erb
Created June 9, 2016 14:48 — forked from rds/contents.erb
Add more customisation options to Compass' sprite importer
@import "compass/utilities/sprites/base";
@mixin sprites($map, $sprite-names, $base-class: false, $dimensions: false, $prefix: sprite-map-name($map), $offset-x: 0, $offset-y: 0) {
@each $sprite-name in $sprite-names {
@if sprite_does_not_have_parent($map, $sprite-name) {
$full-sprite-name: "#{$prefix}#{$sprite-name}";
.#{$full-sprite-name} {
@if $base-class { @extend #{$base-class}; }
@include sprite($map, $sprite-name, $dimensions, $offset-x, $offset-y);
}