Skip to content

Instantly share code, notes, and snippets.

View yaroschiffelers's full-sized avatar
〰️
⏢⏀⎌⑂

Yaro Schiffelers yaroschiffelers

〰️
⏢⏀⎌⑂
View GitHub Profile
@yaroschiffelers
yaroschiffelers / enhanceStackTrace.js
Created July 19, 2019 17:32
Enhance Stack Trace Method (from nodejs/node/lib/events.js)
function enhanceStackTrace(err, own) {
const sep = '\nEmitted \'error\' event at:\n';
const errStack = err.stack.split('\n').slice(1);
const ownStack = own.stack.split('\n').slice(1);
const [ len, off ] = identicalSequenceRange(ownStack, errStack);
if (len > 0) {
ownStack.splice(off + 1, len - 2,
' [... lines matching original stack trace ...]');
@yaroschiffelers
yaroschiffelers / form_reset.sass
Created February 27, 2019 22:57 — forked from dwarfmondo/form_reset.sass
Remove all visual style from form fields
// Note: This file is dependent on Sass and Compass.
// Sass = http://sass-lang.com
// Compass = http://compass-style.org
@import compass/css3
// `Form Element Reset.
//----------------------------------------------------------------------------------------------------
::-moz-focus-inner
/**
* Generate all the .vue pages and gql query-files you need for any given Craft CMS content-type/section.
* @author Yaro Schiffelers - 2019
*/
const fs = require('fs')
const _ = require('lodash')
const junk = require('junk')
const path = require('path')
const fetch = require('node-fetch')
/**
* Advent of Code 2018
* Day 1, first puzzle
* @author Yaro Schiffelers
*/
const data = require('./data/day01')
/**
* Matches the first '+' sign, if any, inside a sting.
// Off-grid layout simple setup.
// 3 cols. 1: off-grid-left, 2: main-grid, 3: off-grid-right;
.layout {
display: grid;
grid-template-columns:
[full-start] minmax($min-width-off-grid-columns, 1fr)
[main-start] minmax(0, $main-grid-max-width) [main-end]
minmax($min-width-off-grid-columns, 1fr) [full-end];
}
/**
* Add To Home Screen Chrome 68+
*
* Changes to Add to Home Screen Behavior has the full details, including code samples you can use and more:
* https://developers.google.com/web/updates/2018/06/a2hs-updates
*
* Credit: https://developers.google.com/web/updates/2018/07/nic68#a2hs
* Add to home screen app criteria: https://developers.google.com/web/fundamentals/app-install-banners/#criteria
*/
@yaroschiffelers
yaroschiffelers / effective-engineer.md
Last active January 29, 2019 15:27
[Effective Engineer Notes] Tips, tricks, and other resources for getting better at effective enginering #notes #productivity #EffectiveEngenering #tips

FWIW: I didn't produce the content present here. I've just copy-pasted it from somewhere over the Internet, but I cannot remember exactly the original source. I was also not able to find the author's name, so I cannot give him/her the proper credit.


Effective Engineer - Notes

What's an Effective Engineer?