Skip to content

Instantly share code, notes, and snippets.

View konstantingassmann's full-sized avatar

Konstantin Gassmann konstantingassmann

  • frankfurt/germany
View GitHub Profile
@konstantingassmann
konstantingassmann / svgicons.rb
Created May 12, 2016 22:11
liquid tag to display a symbol from your svg icon file. Takes the symbol id as argument.
module Jekyll
class SvgiconTag < Liquid::Tag
def initialize(tag_name, icon, tokens)
super
@icon = icon.gsub(/\s+/, "")
end
def render(context)
"<svg class=\"icon\" role=\"img\" width=\"24\" height=\"24\"><use xlink:href=\"/assets/icons.svg\##{@icon}\"></use></svg>"
@konstantingassmann
konstantingassmann / 0_reuse_code.js
Created September 28, 2015 10:16
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console