Skip to content

Instantly share code, notes, and snippets.

View markknol's full-sized avatar
🧪
Doodling around

Mark Knol markknol

🧪
Doodling around
View GitHub Profile
@:remove
@:autoBuild(SkipSerializeMacro.build())
interface ISkipSerialize {}
@pbojinov
pbojinov / README.md
Last active June 27, 2025 05:25
Two way iframe communication- Check out working example here: http://pbojinov.github.io/iframe-communication/

Two way iframe communication

The main difference between the two pages is the method of sending messages. Recieving messages is the same in both.

Parent

Send messages to iframe using iframeEl.contentWindow.postMessage Recieve messages using window.addEventListener('message')

iframe

@catseye
catseye / The Swallows of Summer.markdown
Created November 3, 2013 19:08
The first four chapters of my second novel for NaNoGenMo. It is a sequel to the first novel. It's three years later, and Alice and Bob live in a much bigger house now, and own more things.

The Swallows of Summer

Chapter 1.

The day was overcast and humid. Alice was in the dining room. Alice saw the golden falcon. Bob was in Bob's bedroom. Alice picked up the golden falcon. Bob went to the upstairs hall. Alice hid the golden falcon in the cabinet. Alice went to the kitchen. Bob went to the front hall. Alice examined the cupboards carefully. Alice went to the front hall. Alice saw Bob. 'Hello, Bob,' said Alice. 'Hello, Alice,' replied Bob. Alice went to the kitchen. Bob went to the kitchen. Bob saw Alice. 'Hello, Alice,' said Bob. 'Hello, Bob,' replied Alice. 'Lovely weather we're having, isn't it?' asked Alice. 'Perhaps, Alice,' replied Bob.

'Oh, I know, I know,' said Alice. Bob nodded. Alice went to the front hall. It was so nice being in the front hall again! Bob examined the cupboards carefully. Bob went to the dining room. Alice went to the living room. Bob went to the kitchen. Alice went to the front hall. Bob went to the d

@catseye
catseye / The Swallows.markdown
Created November 3, 2013 12:28
The first chapter of my first novel for NaNoGenMo. This exciting action continues non-stop throughout the next 14 chapters, but the word count is just shy of 50K (only 49,619 words...)

The Swallows

CHAPTER 1

Alice went to the dining room. Alice saw the golden falcon. Bob went to the dining room. Bob saw the golden falcon. Bob saw Alice. Alice picked up the golden falcon. Alice went to the living room. Bob went to the kitchen. Alice went to the dining room. Bob went to the dining room. Bob saw Alice. Bob saw Alice was carrying something. Alice went to the living room. Bob went to the kitchen. Alice went to the dining room. Bob went to the dining room. Bob saw Alice. Bob saw Alice was carrying something. Alice went to the living room. Bob went to the kitchen.

Alice went to the dining room. Bob went to the dining room. Bob saw Alice. Bob saw Alice was carrying something. Alice went to the kitchen. Bob went to the living room. Alice yawned. Bob went to the dining room. Alice went to the dining room. Alice saw Bob. Bob went to the living room. Alice went to the kitchen. Bob went to the dining room. Alice yawned. Bob went to the kitch

@tong
tong / haxe.svg
Created April 20, 2013 12:16
Haxe logo svg (optimized)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
<?php
function gfm($text){
# Extract pre blocks
$extractions = array();
$text = preg_replace_callback('/<pre>.*?<\/pre>/s', function($matches) use (&$extractions){
$match = $matches[0];
$md5 = md5($match);
$extractions[$md5] = $match;