Skip to content

Instantly share code, notes, and snippets.

View triskweline's full-sized avatar

Henning Koch triskweline

View GitHub Profile
@triskweline
triskweline / jquery_shuffle_children.js
Created November 15, 2018 08:44 — forked from joseluisq/jquery_shuffle_children.js
Shuffle child elements with jQuery
jQuery.fn.shuffleChildren = function(){
var p = this[0];
for (var i = p.children.length; i >= 0; i--) {
p.appendChild(p.children[Math.random() * i | 0]);
}
};
@triskweline
triskweline / test.html
Created June 24, 2018 07:59
Custom Elements v0 vs. DOMParser
<!doctype html>
<html>
<head>
<title>Custom elements test</title>
</head>
<body>
<h3>Custom elements from HTML</h3>
<ol class="from-html" start="0">
Foo Bar
---
Bar bam

You Look Nice Today

A sample application for our Rails workshop

This is the demo application for our Rails Workshop, a yearly event held by makandra to tell students about the Ruby on Rails framework and test-driven development.

# Headline 1
## Headline 2
### Headline 3
#### Headline 4
xml.instruct!
xml.rss :version => '2.0', 'xmlns:atom' => 'http://www.w3.org/2005/Atom' do
xml.channel do
xml.title "makandra cards for #{@user.public_name}"
xml.link sites_url
xml.language 'en'
xml.tag! 'atom:link', :rel => 'self', :type => 'application/rss+xml', :href => sites_url
for note in @notes
Foo
- foo
- bar
code
code
- baz
Test
- foo
- bar
baz
- bam