Skip to content

Instantly share code, notes, and snippets.

@hontas
Created November 22, 2018 11:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hontas/66926ed4197ad396c490bb2c933d070d to your computer and use it in GitHub Desktop.
Save hontas/66926ed4197ad396c490bb2c933d070d to your computer and use it in GitHub Desktop.
{
"console.log": {
"prefix": "c",
"body": [
"console.log('$1', ${2:$1});"
]
},
"import": {
"prefix": "imp",
"body": [
"import $1 from '${1/([a-z])([A-Z])/$1-${2:/downcase}/g}';"
]
},
"require": {
"prefix": "req",
"body": [
"const $1 = require('${2:$1}');"
]
},
"export": {
"prefix": "exp",
"body": [
"export ${1:default} $0;"
]
},
"arrow function": {
"prefix": "f",
"body": [
"($1) => {2:{}};"
]
},
"anonymous function": {
"prefix": "fn",
"body": [
"function($1) {",
" $0",
"};"
]
},
"named function": {
"prefix": "fun",
"body": [
"function $1($2) {",
" $0",
"};"
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment