File tree Expand file tree Collapse file tree 2 files changed +48
-2
lines changed Expand file tree Collapse file tree 2 files changed +48
-2
lines changed Original file line number Diff line number Diff line change 11# es6-react-redux-snippets
22This is the best package ever created for ES6, React and Redux
3+
4+
5+ TODO: ADD snippets list
Original file line number Diff line number Diff line change 55' .source.js' :
66 ' Annonymous function' :
77 ' prefix' : ' anfn'
8- ' body' : ' (${1:params}) => {
8+ ' body' : """ (${1:params}) => {
99 $2
10- }'
10+ }"""
11+
12+ ' .source.js' :
13+ ' Named function' :
14+ ' prefix' : ' nfn'
15+ ' body' : ' const ${1:functionName} = (${2:params}) => { $3 }'
1116
1217' .source.js' :
1318 ' function' :
1419 ' prefix' : ' fn'
1520 ' body' : """ function ${1:functionName} (${2:params}) {
1621 $3
1722 }"""
23+
24+ ' .source.js' :
25+ ' Import snippet' :
26+ ' prefix' : ' imp'
27+ ' body' : """ import ${1:ModuleName} from '${2:Module}';"""
28+
29+
30+ ' .source.js' :
31+ ' Import destructured' :
32+ ' prefix' : ' imd'
33+ ' body' : """ import { ${1:destructuredModule} } from '${2:module}'"""
34+
35+ ' .source.js' :
36+ ' Import Everything' :
37+ ' prefix' : ' ime'
38+ ' body' : """ 'import * as ${1:alias} from '${2:module}'"""
39+
40+
41+
42+ # React
43+ ' .source.js' :
44+ ' React Component Snipet' :
45+ ' prefix' : ' rcc' fl
46+ ' body' : """ import React, { Component } from 'react';
47+
48+ export default class ${1:componentName} extends Component {
49+ render() {
50+ return (
51+ <div>
52+ $2
53+ </div>
54+ )
55+ }
56+ }
57+
58+
59+ """
60+
You can’t perform that action at this time.
0 commit comments