From c78b4c64e4e4451f9fb05ac38ed34b9d014ff1fc Mon Sep 17 00:00:00 2001 From: Niklas Date: Fri, 17 Jul 2020 17:54:13 +0200 Subject: [PATCH] vscode scnippet for ts-react --- .../User/snippets/typescriptreact.json | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 .config/Code - OSS/User/snippets/typescriptreact.json diff --git a/.config/Code - OSS/User/snippets/typescriptreact.json b/.config/Code - OSS/User/snippets/typescriptreact.json new file mode 100644 index 0000000..3957733 --- /dev/null +++ b/.config/Code - OSS/User/snippets/typescriptreact.json @@ -0,0 +1,24 @@ +{ + "Component": { + "prefix": "comp", + "description": "Default react component", + "body": [ + "import * as React from \"react\";", + "", + "class $1 extends React.Component {", + "\tconstructor(props) {", + "\t\tsuper(props);", + "\t}", + "", + "\trender(): JSX.Element {", + "\t\treturn
", + "\t\t\tMy $1", + "\t\t
;", + "\t}", + "", + "}", + "", + "export default $1;" + ] + } +} \ No newline at end of file