This file contains hidden or 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
## How to run | |
# | |
# npm run main /invalid | |
# | |
const get = url => { | |
if (url.indexOf('/invalid') >= 0) { | |
return Promise.reject({ | |
url, | |
error: 'error message', |
This file contains hidden or 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
'use strict'; | |
function $(el) { | |
function $Element() { | |
const self = this; | |
this.$is$ = function $is$() { | |
return true; | |
}; | |
this.style = function style(key, value) { | |
if (/(left|right|top|bottom|background-position-x|background-position-y)/i.test(key)) { |
This file contains hidden or 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
export interface ExternalizedPromise<T> { | |
promise: Promise<T>; | |
resolve: (value?: T | PromiseLike<T>) => void; | |
reject: (reason?: any) => void; | |
} | |
export default { | |
create: function create<T>( | |
executor: (resolve: (value?: T | PromiseLike<T>) => void, rejector: (reason?: any) => void) => void |
This file contains hidden or 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 should be at this path | |
# ~/.oh-my-zsh/themes/thiagoh.zsh-theme | |
local ret_status="%(?:%{$fg_bold[green]%}➜ :%{$fg_bold[red]%}➜ )" | |
PROMPT='${ret_status}%{$fg[cyan]%}%c%{$reset_color%} $(git_prompt_info)' | |
PROMPT='%{$fg[green]%}%n ${ret_status}%{$fg[cyan]%}%c%{$reset_color%} $(git_prompt_info)' | |
ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg_bold[blue]%}git:(%{$fg[red]%}" | |
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%} " | |
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[blue]%}) %{$fg[yellow]%}✗" |
This file contains hidden or 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
{ | |
"global": { | |
"check_for_updates_on_startup": true, | |
"show_in_menu_bar": true, | |
"show_profile_name_in_menu_bar": false | |
}, | |
"profiles": [ | |
{ | |
"complex_modifications": { | |
"parameters": { |
This file contains hidden or 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
{ | |
"success": true, | |
"credits_left": 19993, | |
"rate_limit_left": 19999, | |
"person": { | |
"publicIdentifier": "eden-marco", | |
"linkedInIdentifier": "ACoAABx4394BeQhL15XiUqnQf7d9fobHXw13SMo", | |
"memberIdentifier": "477683678", | |
"linkedInUrl": "https://www.linkedin.com/in/eden-marco", | |
"firstName": "Eden", |
OlderNewer