Instantly share code, notes, and snippets.

View timeago.js
const timeago = (ts) => {
const templates = {
prefix: '',
suffix: ' ',
secs: 'just now',
minute: 'a minute ago',
minutes: '%d minutes ago',
hour: 'an hour ago',
hours: '%d hours ago',
day: 'a day ago',
View .eslintrc
"parser": "babel-eslint",
"parserOptions": {
"ecmaVersion": 6,
"sourceType": "module",
"ecmaFeatures": {
"jsx": true,
"modules": true,
"experimentalObjectRestSpread": true

Dashbored file specification

Dashboard files for the Dashbored app for Apple TV and iPhone are JSON files with a certain structure.

A dashboard file should be a JSON object with at least the keys title and sections, and optionally the key theme.


The title key should always exist and contain a string value of the title you want displayed at the top of the dashboard.

View dashboard.json
"title": "Our chicken farm",
"theme": {
"dashboardBackgroundColor": "green",
"dashboardBackgroundImage": "",
"dashboardTitleColor": "#ffffff",
"headerColor": "#666",
"textColor": "#121212",
"backgroundColor": "#ffffff",
"borderRadius": 10,
View dribbble-shots.php
// Set username
$username = 'tschoffelen';
// Get page contents
$content = file_get_contents('' . $username . '?page=1&per_page=12');
// Parse page content into $shots array
$shots = [];
View webpack.config.js
* Why is this here you ask? React Native doesn't use Webpack. True. This file is here to trick
* IDEA in recognizing module aliases (see the package.json files in some of the subdirs).
* Nice solution? No. Does it work? Sure.
* Tracker URL:
* - TS
const fs = require('fs')

Keybase proof

I hereby claim:

  • I am tschoffelen on github.
  • I am tschoffelen ( on keybase.
  • I have a public key whose fingerprint is C641 268A D15D 2BE9 8520 E121 69C2 60E1 D863 6ECA

To claim this, I am signing this object:

View DB2.php
class DB {
private static $_instance = null;
private $_pdo,
$_error = false,
$_count = 0;
private function __construct() {

API Specificatie



View UserSettings.m
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
// Get saved cache data
[self pullData];
// Add some things
[ setObject:@"something" forKey:@"example"];
// Save to file
[self commitData];