Last active
September 11, 2019 21:45
-
-
Save msssk/c639e945933184882b069620957d5cd6 to your computer and use it in GitHub Desktop.
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
Show hidden characters
{ | |
"React Native Web widget": { | |
"scope": "typescriptreact", | |
"prefix": "rn-widget", | |
"description": "RNW widget with standard imports and props", | |
"body": [ | |
"import * as React from 'react';", | |
"import { Component } from 'react';", | |
"import { View } from 'react-native';", | |
"import { styles } from './$TM_FILENAME_BASE.styles';", | |
"", | |
"export interface ${TM_FILENAME_BASE}Props {}", | |
"", | |
"export class $TM_FILENAME_BASE extends Component<${TM_FILENAME_BASE}Props> {", | |
"\trender() {", | |
"\t\treturn <View style={styles.root}></View>;", | |
"\t}", | |
"}", | |
"" | |
] | |
}, | |
"React Native Web widget styles": { | |
"scope": "typescript", | |
"prefix": "rn-styles", | |
"description": "RNW widget styles", | |
"body": [ | |
"import { StyleSheet } from 'react-native';", | |
"import { bg } from '~styles';", | |
"", | |
"export const styles = StyleSheet.create({", | |
"\troot: {}", | |
"});", | |
"" | |
] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment