Skip to content

Instantly share code, notes, and snippets.

View GiancarlosIO's full-sized avatar
🔥
Making the web faster!

Giancarlos Isasi GiancarlosIO

🔥
Making the web faster!
View GitHub Profile
// This file was initially generated by Windows Terminal 1.4.3243.0
// It should still be usable in newer versions, but newer versions might have additional
// settings, help text, or changes that you will not see unless you clear this file
// and let us generate a new one for you.
// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
{
"$schema": "https://aka.ms/terminal-profiles-schema",
@GiancarlosIO
GiancarlosIO / machine.js
Last active August 24, 2020 19:54
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@GiancarlosIO
GiancarlosIO / machine.js
Last active July 30, 2020 16:49
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
const not = fn => (...args) => !fn(...args);
const isZero = (context, event) => event.key === 0;
const isNotZero = not(isZero);
const isMinus = (context, event) => event.operator === '-';
const isNotMinus = not(isMinus);
const divideByZero = (context, event) => {
return (
(!context.operand2 || context.operand2 === '0.') && context.operator === '/'
);
@GiancarlosIO
GiancarlosIO / machine.js
Last active November 12, 2019 03:36
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@GiancarlosIO
GiancarlosIO / eslint.json
Created October 30, 2018 04:46 — forked from BilalBudhani/eslint.json
Wesbos' eslint + prettier config
{
"extends": [
"airbnb",
"prettier",
"prettier/react"
],
"parser": "babel-eslint",
"parserOptions": {
"ecmaVersion": 8,
"ecmaFeatures": {
module.exports = {
// ... el resto de tu configuración
entry: {
app: './static/js/app.js',
},
output: {
// el output.publicPath debe coincidir con el publicPath del devServer
publicPath: 'http://localhost:9000/static/js/',
filename: '[name].min.js',
},
{
// Place your snippets for javascriptreact here. Each snippet is defined under a snippet name and has a prefix, body and
// description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the
// same ids are connected.
// Example:
// "Print to console": {
// "prefix": "log",
// "body": [
// "console.log('$1');",
# create and enter to folder
function mkcdir() {
mkdir -- "$1"
cd -- "$1"
}
# show ip
alias myip='curl http://ipecho.net/plain; echo'
alias nis='npm install --save'
# useful git aliases
[alias]
ls = log --pretty=format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate
ll = log --pretty=format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --numstat
lnc = log --pretty=format:"%h\\ %s\\ [%cn]"
lds = log --pretty=format:"%C(yellow)%h\\ %ad%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --date=short
la = "!git config -l | grep alias | cut -c 7-"
s= status
ck = checkout
a = add