Skip to content

Instantly share code, notes, and snippets.

@MalucoMarinero
MalucoMarinero / gist:9797472
Last active August 29, 2015 13:57
Fat Frontend
So, I'm gonna make a book. It's gonna start off as a document in sphinx-doc, so I just
publish as a flat file HTML, and then maybe figure out funding it if there's enough
interest in the output. The subject of the book would be an open source project that can
be completely viewed on it's own, and the idea is that the book would go through the
technologies involved, the decision process, and how it's all structured together to
build a self sufficient Frontend client.
Key ideas are a structure of modular components, that means when you end up with shit
going out of date, you don't have to change everything to adapt. Give new technology
@mx-moth
mx-moth / rev-sax.js
Created May 8, 2014 05:05
Reverse sax parser
"use strict";
function processNodeList(list, target) {
list.forEach(function(node) {
processNode(node, target);
});
}
function processNode(node, target) {
switch (node._type) {
@trixpan
trixpan / How-to Arch Linux on Cubieboard 1.md
Last active July 21, 2021 17:10
How to really Arch Linux on Cubieboard 1.... (for the Wiki entry is sort of short of some things)

Intro Notes

I wrote this guide because after getting my CubieBoard 1 I followed the Arch Linux ARM instructions and was suprised to be left with a system that albeit working, had missing RAM and no fbconsole at all.

This guide gets Arch Linux ARM into your 1GB Cubieboard 1 with the minimum functionality one would expect. It is not intended to be an all encompassing document, focusing instead on saving your time having to read through the forum to get functionality that otherwise every other Linux distribution brings out of box.

You will have to adjust these instructions if you have a 512M Cubieboard.

Step 1 - Format disk your SD Card

At a minimum, you need to create the first partition on an SD card to store the bootloader files and kernel uImage. For the root filesystem you can choose to use either a second partition on the SD card, USB or SATA. This guide however only covers SD. Replace instances of /dev/mmcblkX with the appropriate device name registered on your system.

@rwaldron
rwaldron / tdz-1.js
Last active April 4, 2018 21:20
Temporal Dead Zone
{
// The block has begun, we're in a new block scope. The TDZ for the "a" binding has begun
var f = function() {
// 2. Because f() is evaluated before `a` is actually declared,
// an exception will be thrown indicating to the author that
// `a` is not yet defined.
console.log(a);
};
var connect = require('multilevel-connect');
var db = connect('password@host:port');
db.createReadStream()
.on('data', function(kv){
console.log(JSON.stringify(kv));
})
.on('end', function(){
process.exit(0)
@staltz
staltz / introrx.md
Last active April 29, 2025 08:33
The introduction to Reactive Programming you've been missing
@snekse
snekse / ExportCSV.md
Last active February 15, 2016 20:15
Export data to CSV client side in IE without data URI link

Export data to CSV client side in IE without data URI link

@addyosmani
addyosmani / README.md
Last active April 29, 2025 13:39 — forked from 140bytes/LICENSE.txt
108 byte CSS Layout Debugger

CSS Layout Debugger

A tweet-sized debugger for visualizing your CSS layouts. Outlines every DOM element on your page a random (valid) CSS hex color.

One-line version to paste in your DevTools

Use $$ if your browser aliases it:

~ 108 byte version

Give me back my sanity

One of the many things I do for my group at work is to take care of automating as many things as possible. It usually brings me a lot of satisfaction, mostly because I get a kick out of making people's lives easier.

But sometimes, maybe too often, I end up in drawn-out struggles with machines and programs. And sometimes, these struggles bring me to the edge of despair, so much so that I regularly consider living on a computer-less island growing vegetables for a living.

This is the story of how I had to install Pandoc in a CentOS 6 Docker container. But more generally, this is the story of how I think computing is inherently broken, how programmers (myself included) tend to think that their way is the way, how we're ultimately replicating what most of us think is wrong with society, building upon layers and layers of (best-case scenario) obscure and/or weak foundations.

*I would like to extend my gratitude to Google, StackOverflow, GitHub issues but mostly, the people who make the

@loveencounterflow
loveencounterflow / fill-and-read-db.js
Last active August 29, 2015 14:13
`lte` key limits in LevelDB and Unicode
// Generated by CoffeeScript 1.8.0
(function() {
var $, D, db, db_route, feed, fs, gte, keys, log, new_db, read, rmrf, rpr, through2;
fs = require('fs');
log = console.log;
rpr = (require('util')).inspect;