-
-
Save paulserraino/4399d4ed073d7b06b234b611e8422566 to your computer and use it in GitHub Desktop.
VSCode User Snippets
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
{ | |
"log": { | |
"prefix": "log", | |
"body": "console.log('${0}');", | |
"description": "Log output to console" | |
}, | |
"import": { | |
"prefix": "impo", | |
"body": "import ${1} from '${2}';${0}", | |
"description": "Creates es6 import" | |
}, | |
"require": { | |
"prefix": "req", | |
"body": "const ${1} = require('${2}');\n${0}", | |
"description": "Creates es6 require" | |
}, | |
"constructor": { | |
"prefix": "con", | |
"body": "constructor(${1}) {\n\tsuper(${1});\n\t${0}\n}", | |
"description": "Add default constructor in a class in ES6 syntax" | |
}, | |
"method": { | |
"prefix": "meth", | |
"body": "${1:methodName} = (${2:params}) => {\n\t${0}\n}", | |
"description": "Creates a method inside a class in ES6 syntax" | |
}, | |
"propTypes": { | |
"prefix": "prop", | |
"body": "${1:prop}: PropTypes.${0},", | |
"description": "Creates a prop with propTypes" | |
}, | |
"function": { | |
"prefix": "fu", | |
"body": "function ${1}(${2}){\n\t${0}\n}", | |
"description": "Creates a es5 function" | |
}, | |
"describe": { | |
"prefix": "desc", | |
"body": "describe('${1}', function() {\n\t${0}\n});" | |
}, | |
"it": { | |
"prefix": "it", | |
"body": "it('should ${1}');${0}", | |
"description": "Creates an it block." | |
}, | |
"toBe": { | |
"prefix": "to", | |
"body": "expect(${1}).toBe(${0});", | |
"description": "Creates a toBe Jest assertion" | |
}, | |
"toEqual": { | |
"prefix": "toe", | |
"body": "expect(${1}).toEqual(${0});", | |
"description": "Creates a toEqual Jest assertion" | |
}, | |
"find": { | |
"prefix": "find", | |
"body": "component.find('${1}')${0}", | |
"description": "Creates a Enzyme find function" | |
}, | |
"shallow": { | |
"prefix": "shal", | |
"body": "component = shallow(\n\t<${1:Component}\n\t\t${0:props}\n\t/>\n);" | |
}, | |
"mount": { | |
"prefix": "mou", | |
"body": "component = mount(\n\t<${1:Component}\n\t\t${0:props}\n\t/>\n);" | |
}, | |
} |
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
{ | |
"editor.renderWhitespace": "all", | |
"workbench.editor.tabSizing": "shrink", | |
"workbench.colorTheme": "Atom One Dark", | |
"editor.minimap.enabled": false, | |
"editor.tabSize": 2, | |
"editor.insertSpaces": true, | |
"explorer.confirmDragAndDrop": false, | |
"editor.acceptSuggestionOnCommitCharacter": false, | |
"typescript.autoImportSuggestions.enabled": false, | |
"editor.snippetSuggestions": "top", | |
"emmet.includeLanguages": { | |
"javascript": "javascriptreact" | |
}, | |
"emmet.triggerExpansionOnTab": true, | |
"editor.colorDecorators": false, | |
"files.insertFinalNewline": true, | |
"javascript.updateImportsOnFileMove.enabled": "never", | |
"window.nativeTabs": true | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment