Skip to content

Instantly share code, notes, and snippets.

View easierbycode's full-sized avatar

▓▒░ ♔ Daniel ♔ ░▒▓ easierbycode

View GitHub Profile
@easierbycode
easierbycode / 2-fizzbuzz.js
Last active September 14, 2017 02:35
Eloquent JavaScript
var divisibleBy3 = function( num ) { return (num % 3) === 0 }
var divisibleBy5 = function( num ) { return (num % 5) === 0 }
for ( num = 1; num <= 100; num++ ) {
if ( divisibleBy3( num ) ) console.log( 'Fizz: ', num );
if ( divisibleBy5( num ) && !divisibleBy3( num ) ) console.log( 'Buzz: ', num );
if ( divisibleBy3( num ) && divisibleBy5( num ) ) console.log( 'FizzBuzz: ', num );
}
.flex {
-webkit-box-flex: 1;
-ms-flex: 1;
flex: 1;
box-sizing: border-box;
}
[layout]>* {
min-height: auto;
min-height: initial
{
"product": {
"id": 9945959631,
"title": "Nest Learning Thermostat, 3rd Generation",
"handle": "nest-learning-thermostat-3rd-generation",
"description": "\u003cmeta charset=\"utf-8\"\u003e\n\u003cul class=\"a-vertical a-spacing-none\"\u003e\n\u003cli\u003e\u003cspan class=\"a-list-item\"\u003eWorks with Amazon Alexa for voice control (Alexa device sold separately)\u003c\/span\u003e\u003c\/li\u003e\n\u003cli\u003e\u003cspan class=\"a-list-item\"\u003eAuto-Schedule: Nest learns the temperatures you like and programs itself in about a week.\u003c\/span\u003e\u003c\/li\u003e\n\u003cli\u003e\u003cspan class=\"a-list-item\"\u003eHome\/Away Assist: Nest automatically turns itself down when nobody’s home to help you save energy.\u003c\/span\u003e\u003c\/li\u003e\n\u003cli\u003e\u003cspan class=\"a-list-item\"\u003eRemote Control: Connect your thermostat to Wi‑Fi to control the temperature from your phone, tablet or laptop.\u003c\/span\u003e\u003c\/li\u003e\n\u003cli\u003e\u003cspa
@easierbycode
easierbycode / waveform.json
Created June 30, 2017 00:18
invaders flight path
[null, {
"type": 0,
"closed": false,
"x": [0, 128, 256, 384, 512, 640],
"y": [70, 78, 316, 78, 319, 396]
}, {
"type": 0,
"closed": false,
"x": [0, 128, 256, 384, 512, 640],
"y": [413, 88, 324, 292, 71, 98]
{
"activityMeasures" : {
"A9k1Vuas8ofmhjPeA3zbL7LgKSF3" : {
"2016" : {
"11" : {
"28" : {
"calories" : 1008.211,
"date" : "2016-11-28",
"distance" : 16059.18,
"elevation" : 0,
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<title> | Vantage Freight</title>
@easierbycode
easierbycode / README.md
Last active April 6, 2017 22:47
offline Google Analytics script. customized IIFE to avoid double recording the firstPageView.
{
"amazonEcho" : {
"verifiedFromGpsPosition" : {
"latitude" : 33.5949673,
"longitude" : -112.22971069
},
"verifyDate" : 1461621074549,
"videoUrl" : "http://res.cloudinary.com/dujip8nqb/video/upload/v1461621072/preset_folder/j5jxmk59ly2kcbbrnzox.3gp"
},
@easierbycode
easierbycode / Xorg.crouton.1.log
Created February 20, 2017 19:54
Chromebook Plus crouton error log
[ 2623.408] _XSERVTransmkdir: Owner of /tmp/.X11-unix should be set to root
[ 2623.412]
X.Org X Server 1.15.1
Release Date: 2014-04-13
[ 2623.412] X Protocol Version 11, Revision 0
[ 2623.412] Build Operating System: Linux 3.2.0-67-highbank armv7l Ubuntu
[ 2623.412] Current Operating System: Linux localhost 4.4.21-06459-ge91c124 #1 SMP PREEMPT Thu Feb 16 21:44:33 PST 2017 aarch64
[ 2623.413] Kernel command line: cros_secure console= loglevel=7 init=/sbin/init cros_secure oops=panic panic=-1 root=/dev/dm-0 rootwait ro dm_verity.error_behavior=3 dm_verity.max_bios=-1 dm_verity.dev_wait=1 dm="1 vroot none ro 1,0 3334144 verity payload=PARTUUID=12a8c470-5762-934e-adb4-39c1a1843329/PARTNROFF=1 hashtree=PARTUUID=12a8c470-5762-934e-adb4-39c1a1843329/PARTNROFF=1 hashstart=3334144 alg=sha1 root_hexdigest=e3e53317ec954498262bc23247e1d0a9952b1acf salt=202cffe272c3df43a1e5493b640bd893970a059823ea7fd76a30d42f355942aa" noinitrd vt.global_cursor_default=0 kern_guid=12a8c470-5762-934e-adb4-39c1a1843329
[ 2623.413]
{
"deviceType": "urn:Belkin:device:controllee:1",
"friendlyName": "Desk light",
"manufacturer": "Belkin International Inc.",
"manufacturerURL": "http://www.belkin.com",
"modelDescription": "Belkin Plugin Socket 1.0",
"modelName": "Socket",
"modelNumber": "1.0",
"modelURL": "http://www.belkin.com/plugin/",
"serialNumber": "221651K0100262",