Skip to content

Commit 80c8ce2

Browse files
authored
Merge pull request #1 from UruIT/develop
develop > master (1.2.0) - snippet choices support (`u-pt`) - changelog update - readme badges
2 parents c499d69 + f4d57b2 commit 80c8ce2

File tree

4 files changed

+45
-10
lines changed

4 files changed

+45
-10
lines changed

CHANGELOG.md

+35-5
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,45 @@
11
# Change Log
2-
All notable changes to the "uruit-react-snippets" extension will be documented in this file.
2+
3+
All notable changes to the `uruit-react-snippets` extension will be documented in this file.
34

45
Check [Keep a Changelog](http://keepachangelog.com/) for recommendations on how to structure this file.
56

6-
## [Unreleased]
7-
- Initial release
7+
## `[1.2.0]` · 2017-08-22
8+
9+
### Added
10+
- Snippet choices support
11+
12+
### Changed
13+
- React PropType snippet (`u-pt`) with options for:
14+
* array
15+
* bool
16+
* func
17+
* number
18+
* object
19+
* string
20+
* symbol
21+
* node
22+
* element
23+
* any
24+
- Log output to console (`u-ci`) with options for:
25+
* info
26+
* log
27+
* error
28+
29+
## `[1.1.2]` · 2017-07-06
30+
31+
### Added
32+
- Redux reducer snippet (`u-reducer`)
33+
34+
## `[1.1.1]` · 2017-07-04
835

9-
## [1.1.1] - 2017-07-04
1036
### Added
1137
- CHANGELOG.md
1238
- Troubleshooting section in README.md
39+
1340
### Changed
14-
- Update `u-suite` snippet
41+
- Update Jest Test Suite snippet (`u-suite`)
1542

43+
44+
## [Unreleased]
45+
- Initial release

README.md

+6-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# React Snippets for Visual Studio Code
22

3+
[![](https://vsmarketplacebadge.apphb.com/version/UruIT.uruit-react-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=UruIT.uruit-react-snippets)
4+
[![](https://vsmarketplacebadge.apphb.com/installs/UruIT.uruit-react-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=UruIT.uruit-react-snippets)
5+
6+
37
Extension for Visual Studio Code to add snippets for React in ECMAScript 6.
48

59
![Extension demo](./images/snippet-demo.gif)
@@ -10,7 +14,7 @@ Type the snippet prefix and press enter.
1014

1115
* General
1216
```javascript
13-
u-ci // console.info
17+
u-ci // console.info|log|error
1418
u-cn // JSX element class name
1519
u-ctor // Class constructor
1620
u-impt // Import module statement
@@ -20,7 +24,7 @@ u-rfc // Functional component (stateless)
2024

2125
* PropTypes
2226
```javascript
23-
u-pt // Generic PropType
27+
u-pt // Generic PropType (string|number|func|...)
2428
u-pta // Array PropType
2529
u-ptany // Any PropType
2630
u-ptarrayof // Array Of (PropType)

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "uruit-react-snippets",
33
"displayName": "UruIT React Snippets",
44
"description": "React Snippets with ECMAScript 6",
5-
"version": "1.1.2",
5+
"version": "1.2.0",
66
"publisher": "UruIT",
77
"icon": "images/uruit-logo.png",
88
"engines": {

snippets/snippets.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
"Print to console": {
33
"prefix": "u-ci",
44
"body": [
5-
"console.info('$1');"
5+
"console.${1|info,log,error|}('$2');",
6+
"$0"
67
],
78
"description": "Log output to console"
89
},
@@ -124,7 +125,7 @@
124125
"PropTypes": {
125126
"prefix": "u-pt",
126127
"body": [
127-
"$1: PropTypes.$2.isRequired"
128+
"$1: PropTypes.${2|string,number,bool,func,array,object,symbol,element,node,any|}.isRequired"
128129
],
129130
"description": "React PropType"
130131
},

0 commit comments

Comments
 (0)