Last active
September 14, 2017 04:37
-
-
Save inifaisal/3ae3e5bfda9835f95f465b5638347f92 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
{ | |
"Add Author Comment": { | |
"prefix": "author", | |
"body": [ | |
"/**", | |
" * Author: Your mae", | |
" * Email: [email protected]", | |
" */" | |
], | |
"description": "add author comment" | |
}, | |
// console.log() is important than other snippet | |
"Print to console": { | |
"prefix": "log", | |
"body": ["console.log('$1');", "$2"], | |
"description": "Log output to console" | |
}, | |
"Create React Native Component": { | |
"prefix": "crnc", | |
"body": [ | |
"import React, { Component } from 'react'", | |
"import {", | |
" View,", | |
" Text,", | |
" StyleSheet,", | |
"} from 'react-native';", | |
"", | |
"class $1 extends Component {", | |
" render() {", | |
" return (", | |
" <View style={styles.container}>", | |
" <Text>$1</Text>", | |
" </View>", | |
"", | |
" )", | |
" }", | |
"}", | |
"", | |
"const styles = StyleSheet.create({", | |
" container: {", | |
" }", | |
"});", | |
"", | |
"export default $1", | |
"" | |
], | |
"description": "Create React Native Component" | |
}, | |
"Create React Native Stateless Component": { | |
"prefix": "crnsc", | |
"body": [ | |
"import React from 'react'", | |
"import {", | |
" View,", | |
" Text,", | |
" StyleSheet,", | |
"} from 'react-native';", | |
"", | |
"const $1 = () => {", | |
" return (", | |
" <View style={styles.container}><Text>$1</Text></View>", | |
" )", | |
"}", | |
"const styles = StyleSheet.create({", | |
" container: {", | |
" }", | |
"});", | |
"", | |
"export default $1", | |
"" | |
], | |
"description": "Create React Native Stateless Component" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment