Skip to content

Instantly share code, notes, and snippets.

@wunnle
Created April 29, 2020 06:24
Show Gist options
  • Save wunnle/0778103ad015024f17e6667f1d913b73 to your computer and use it in GitHub Desktop.
Save wunnle/0778103ad015024f17e6667f1d913b73 to your computer and use it in GitHub Desktop.

Revisions

  1. wunnle created this gist Apr 29, 2020.
    35 changes: 35 additions & 0 deletions vscode-snippets.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,35 @@
    "import React": {
    "prefix": "imr",
    "body": [
    "import React from 'react' \n \n"
    ]
    },
    "functional component": {
    "prefix": "sfc",
    "body": [
    "import React from 'react' \n",
    "const $1 = () => {",
    "return ('hey')",
    "}",
    "\n",
    "export default $1"
    ]
    },
    "component": {
    "prefix": "fc",
    "body": [
    "import React from 'react'",
    "import styles from './$1.module.scss' \n",
    "const $1 = () => (",
    "<div>hey</div>",
    ")",
    "\n",
    "export default $1"
    ]
    },
    "propTypes": {
    "prefix": "pt",
    "body": [
    "import PropTypes from 'prop-types'"
    ]
    }