Skip to content

Instantly share code, notes, and snippets.

@deepsweet
deepsweet / LICENSE.txt
Created May 26, 2011 20:33 — forked from 140bytes/LICENSE.txt
$$ yocto framework
Copyright (c) 2011 Kir Belevich, http://soulshine.in
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
@eliperelman
eliperelman / LICENSE.txt
Created August 16, 2011 06:09 — forked from 140bytes/LICENSE.txt
Throttling and Debouncing
DO WHAT THE **** YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Eli Perelman <http://eliperelman.com>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE **** YOU WANT TO PUBLIC LICENSE
@rxaviers
rxaviers / gist:7360908
Last active April 18, 2024 16:11
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
@itsamenathan
itsamenathan / poorman.ntp
Created December 16, 2014 14:40
poor mans ntp
date -s "$(curl -s --head http://google.com | awk '/^Date/ {$1=""; print $0}')"

Template composition with inclusion

Every template language I have seen provides some mechanism for one template to include another, thus supporting the reuse of repeated elements like headers and footers. The included templates are called partials in Mustache parlance:

<!-- home.hbs -->
<html>
<body>
  {{> header}}
  <p> HOME </p>
  {{> footer}}
@max-winderbaum
max-winderbaum / depInj.js
Last active September 24, 2017 21:00
Poor Man's Dependency Injection
import dep1 from '../dep1';
import dep2 from '../dep2';
const defaultDeps = {
dep1,
dep2,
};
export function _myModuleFactory({ dep1, dep2 } = defaultDeps) {
const myModule = {};