Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ts snp #18

Open
arcsin1 opened this issue Aug 4, 2023 · 0 comments
Open

ts snp #18

arcsin1 opened this issue Aug 4, 2023 · 0 comments

Comments

@arcsin1
Copy link
Owner

arcsin1 commented Aug 4, 2023

{
"return": {
"prefix": "rt",
"body": [
"return $1"
]
},
"then": {
"prefix": "th",
"body": [
".then(($1) => {$2})"
]
},
"TypeScript react function component 1": {
"prefix": "trfc",
"body": [
"import React from 'react';",
"",
"",
"type I${1:${TM_FILENAME_BASE}}Props = {",
"\tclassName?: string;",
"\tstyle?: React.CSSProperties;",
"};",
"type I${1:${TM_FILENAME_BASE}}State = {};",
"",
"const ${1:${TM_FILENAME_BASE}}: React.FC<I${1:${TM_FILENAME_BASE}}Props> = () => {",
"\treturn (",
"\t\t

",
"\t\t\t${1:${TM_FILENAME_BASE}}",
"\t\t
",
"\t);",
"};",
"",
"export default ${1:${TM_FILENAME_BASE}};",
"",
]
},
"TypeScript react function component constructor": {
"prefix": "tsfc",
"body": [
"import React from 'react';",
"import { Base, Anime } from '@shuwen/use-anime';",
"",
"",
"export type I${1:${TM_FILENAME_BASE}}Props = {",
"\tclassName?: string;",
"\tstyle?: React.CSSProperties;",
"};",
"type I${1:${TM_FILENAME_BASE}}State = {};",
"",
"function ${1:${TM_FILENAME_BASE}}(props:I${1:${TM_FILENAME_BASE}}Props){",
"\treturn (",
"\t\t
",
"\t\t\t${1:${TM_FILENAME_BASE}}",
"\t\t
",
"\t);",
"};",
"",
"",
"${1:${TM_FILENAME_BASE}}.defaultProps = defaultProps;",
"",
"",
"export default ${1:${TM_FILENAME_BASE}};",
"",
]
},
"TSLint disable next line": {
"prefix": "tdnl",
"body": "// tslint:disable-next-line $1",
},
"TSLint disable line": {
"prefix": "tdl",
"body": "// tslint:disable-line $1",
},
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant