Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions snippets/next-javascript.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@
" return {",
" props: {},",
" };",
"};",
""
"};"
],
"description": "Next.js Get Server Side Props Typescript"
},
Expand All @@ -18,8 +17,7 @@
" return {",
" props: {},",
" };",
"};",
""
"};"
],
"description": "Next.js Get Static Props Typescript"
}
Expand Down
12 changes: 6 additions & 6 deletions snippets/next-typescript.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@
" return {",
" props: {},",
" };",
"};",
""
"};"
],
"description": "Next.js Get Server Side Props Typescript"
},
Expand All @@ -18,8 +17,7 @@
" return {",
" props: {},",
" };",
"};",
""
"};"
],
"description": "Next.js Get Static Props Typescript"
},
Expand Down Expand Up @@ -55,16 +53,18 @@
"prefix": "nct",
"body": [
"import type { NextComponentType, NextPageContext } from \"next\";",
"",
"interface Props {}",
"const ${1:${TM_FILENAME_BASE}}: NextComponentType<NextPageContext, {}, Props> = (",
"",
"const ${1:${TM_FILENAME_BASE/(.*)/${1:/capitalize}/}}: NextComponentType<NextPageContext, {}, Props> = (",
" props: Props,",
") => {",
" return (",
" <div></div>",
" )",
"}",
"",
"export default ${1:${TM_FILENAME_BASE}}"
"export default ${1:${TM_FILENAME_BASE/(.*)/${1:/capitalize}/}}"
],
"description": "Next.js Component Typescript"
}
Expand Down
5 changes: 2 additions & 3 deletions snippets/react-javascript.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,10 @@
"React functional component": {
"prefix": "rfc",
"body": [
"const ${1:${TM_FILENAME_BASE}} = () => {",
"const ${1:${TM_FILENAME_BASE/(.*)/${1:/capitalize}/}} = () => {",
" return <div></div>;",
"};",
"export default ${1:${TM_FILENAME_BASE}};",
""
"export default ${1:${TM_FILENAME_BASE/(.*)/${1:/capitalize}/}};"
],
"description": "React functional component"
},
Expand Down
3 changes: 1 addition & 2 deletions snippets/react-typescript.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@
" return <div></div>;",
"}",
"",
"export default ${1:${TM_FILENAME_BASE}};",
""
"export default ${1:${TM_FILENAME_BASE}};"
],
"description": "React functional component Typescript"
}
Expand Down