This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git submodule foreach '[ "$path" == "submodule-to-exclude" ] || git pull origin master' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
i solved the same issue recently for this module and others like --> ngx translate and more... | |
solution (compile the js files into es2015): | |
npm i --save -dev babel-cli babel-preset-es2015 | |
add this to the root project under the name .babelrc | |
{ "presets": ["es2015"] } | |
add a npm script in package.json in "scrtipsts" scope |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let cookies = {}; | |
document.cookie.split(' ').map(x => x.replace(/;$/g, '').split('=')).map(x => { cookies[x[0]] = x[1]; return x; }); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
npm version patch -m 'version(package): update to %s' | |
git push |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
¯\_(ツ)_/¯ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Javascript: | |
/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/ | |
Python: | |
r"(^[a-zA-Z0-9_.+-]+@[a-zA-Z0-9-]+\.[a-zA-Z0-9-.]+$)" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Deconstruction array items | |
const myArray = ['apple', 'nut', 'mies']; | |
const [apple] = myArray; | |
console.log(apple); | |
'apple' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var breakfast = { | |
"cereal" : "fruit loops", | |
"pastry" : undefined | |
}; | |
console.log(breakfast); | |
// -> { cereal: 'fruit loops', pastry: undefined } | |
console.log(JSON.stringify(breakfast)); | |
// -> {"cereal":"fruit loops"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ================== FIXED GRID OVERLAY ================== // | |
// Some calculated settings from the Foundation settings file | |
$base_image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8DgAwAEUgFNvg2eQgAAAABJRU5ErkJggg=='); | |
$width: $global-width - rem-calc(map-get($grid-column-gutter, medium)); | |
$offset: rem-calc(map-get($grid-column-gutter, medium)); | |
$gutter: rem-calc(map-get($grid-column-gutter, medium)); | |
$columns: $grid-column-count; | |
@mixin fixedGridOverlay($width, $columns, $gutter) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const id = 42; | |
const myArray = [ | |
{ | |
id: 1, | |
name: 'foobar', | |
}, | |
{ | |
id: 7, | |
name: 'lucky', |
NewerOlder