Skip to content

Commit

Permalink
#9 #8 Add a snippet for class constructor that contains context as ar…
Browse files Browse the repository at this point in the history
…gument
  • Loading branch information
xabikos committed Mar 14, 2016
1 parent 5fcb781 commit 01ddf73
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions snippets/snippets.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,15 @@
"description": "Creates a stateless React component with PropTypes in ES6 nodule system"
},

"classConstructor": {
"classConstructor": {
"prefix": "con",
"body": "constructor(props) {\n\tsuper(props);\n\t$0\n}\n",
"description": "Adds a default construcotr for the class"
"description": "Adds a default construcotr for the class that contains props as arguments"
},
"classConstructorContext": {
"prefix": "conc",
"body": "constructor(props, context) {\n\tsuper(props, context);\n\t$0\n}\n",
"description": "Adds a default construcotr for the class that contains props and context as arguments"
},

"componentWillMount": {
Expand Down

0 comments on commit 01ddf73

Please sign in to comment.