Skip to content

Commit 9afa44b

Browse files
doctypercwelch5
authored andcommitted
chore: add commitizen + conventional-changelog (#253)
* chore: add commitizen add support for commitizen + conventional-changelog * Merge branch 'master' into chore/codecov
1 parent 7c174a1 commit 9afa44b

File tree

3 files changed

+454
-137
lines changed

3 files changed

+454
-137
lines changed

CHANGELOG.md

Lines changed: 62 additions & 94 deletions
Original file line numberDiff line numberDiff line change
@@ -1,225 +1,193 @@
1-
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
2-
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
3-
**Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)*
4-
5-
- [5.0.0](#500)
6-
- [4.0.0](#400)
7-
- [3.3.2](#332)
8-
- [3.3.1 [BROKEN]](#331-broken)
9-
- [3.3.0](#330)
10-
- [3.2.3](#323)
11-
- [3.2.2](#322)
12-
- [3.2.1 [BROKEN]](#321-broken)
13-
- [3.2.0 [BROKEN]](#320-broken)
14-
- [3.1.0](#310)
15-
- [3.0.2](#302)
16-
- [3.0.1](#301)
17-
- [3.0.0](#300)
18-
- [2.3.1](#231)
19-
- [2.3.0](#230)
20-
- [2.2.0](#220)
21-
- [2.1.1](#211)
22-
- [2.1.0](#210)
23-
- [2.0.0](#200)
24-
- [1.1.5](#115)
25-
- [1.1.4](#114)
26-
- [1.1.3](#113)
27-
- [1.1.2](#112)
28-
- [1.1.1](#111)
29-
- [1.1.0](#110)
30-
- [1.0.1](#101)
31-
- [1.0.0](#100)
32-
33-
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
34-
## 5.0.0
35-
36-
Features:
1+
<a name="5.0.0"></a>
2+
# [5.0.0](https://github.com/nfl/react-helmet/compare/4.0.0...v5.0.0) (2017-03-21)
3+
4+
### Features
375

386
- New Simplified API (fully backward-compatible) - Helmet now takes plain HTML tags for the majority of the API with just a few remaining props for Helmet - retaining `titleTemplate`, `defaultTitle`, `onChangeClientState`, and one new - `encodeSpecialCharacters` - refer to README for details. Directly passing Helmet props will be deprecated in the future. [(#246)](https://github.com/nfl/react-helmet/pull/246)
397
- `requestIdleCallback` utilized to consolidate DOM changes and makes these non-blocking for things like animations. Fixes first client-side render not matching server-side render. Maintains one DOM change between route changes on the client-side as well. [(#248)](https://github.com/nfl/react-helmet/pull/248)
408
- On server-side, `Helmet.renderStatic()` aliased to `Helmet.rewind()` for more clarity. `rewind` will be deprecated in the future.
419
- Yarn support
4210

43-
## 4.0.0
11+
# 4.0.0
4412

45-
Features:
13+
### Features
4614

4715
- Replacing PlainComponent with stateless functional component `NullComponent`, with a hard requirement to use React 15 or higher.
4816

49-
## 3.3.2
17+
# 3.3.2
5018

51-
Bugfixes:
19+
### Bugfixes
5220

5321
- Removed stateless functional component `NullComponent` because of it's incompatibility with React 14 and reverted back to PlainComponent.
5422

55-
## 3.3.1 [BROKEN]
23+
# 3.3.1 [BROKEN]
5624

57-
Bugfixes:
25+
### Bugfixes
5826

5927
- README updates - npm badge and helmet image
6028
- Bump react-side-effect to 1.1.0
6129
- Removing PlainComponent, replaced with NullComponent defined within Helmet.js
6230
- Refactored code - cut lines of code and used `reduce` to simplify functions
6331
- Replaced PlainComponent with NullComponent (now within Helmet.js)
6432

65-
## 3.3.0
33+
# 3.3.0
6634

67-
Features:
35+
### Features
6836

6937
- `itemprop` available in meta tags
7038
- New API - `titleAttributes` to add attributes to the title tag
7139
- `class` support for html tag
7240

73-
## 3.2.3
41+
# 3.2.3
7442

75-
Bugfixes:
43+
### Bugfixes
7644

7745
- applied previous fix (undefined value for primary attribute key) to base tag
7846
- fix htmlAttributes fallback value when calling rewind() on blank Helmet
7947
- Removed unneeded dependencies - shallowequal, warning
8048
- babel configuration moved into .babelrc
8149
- eslint configuration moved into .eslintrc
8250

83-
## 3.2.2
51+
# 3.2.2
8452

85-
Bugfixes:
53+
### Bugfixes
8654

8755
- Removed breaking changes `jsnext:main` and `module` from package.json. `es` version required special babel configuration for end users and needs to be re-thought for major release.
8856
- Reverted `canUseDOM` setter in `Helmet.js`, as this was a breaking change for some users.
8957
- [fix] runtime error when providing undefined value for primary attribute key (applies to meta, link, script, noscript, style)
9058

91-
## 3.2.1 [BROKEN]
59+
# 3.2.1 [BROKEN]
9260

93-
Bugfixes:
61+
### Bugfixes
9462

9563
- Removing "engines" field in package.json.
9664

97-
## 3.2.0 [BROKEN]
65+
# 3.2.0 [BROKEN]
9866

99-
Features:
67+
### Features
10068

10169
- `<noscript>` support
10270

103-
Bugfixes:
71+
### Bugfixes
10472

10573
- Prevent stripping dollar signs from title when titleTemplate is present
10674
- Offering jsnext:main build
10775
- Removed Gulp Dependency
10876
- Bump Dependencies
10977
- IE8 Support
11078

111-
## 3.1.0
79+
# 3.1.0
11280

113-
Features:
81+
### Features
11482

11583
- Add support for `<style>` elements.
11684

117-
## 3.0.2
85+
# 3.0.2
11886

119-
Bugfixes:
87+
### Bugfixes
12088

12189
- Avoids rendering "undefined" if it's passed in as a value of an attribute, but instead renders just the attribute name.
12290
- When htmlAttributes gets cleared, or is blank, the helmet attribute on the html tag, used for tracking, is cleaned up.
12391
- Upgrading devDependency of React to 15.
12492

125-
## 3.0.1
93+
# 3.0.1
12694

127-
Bugfixes:
95+
### Bugfixes
12896

12997
- The htmlAttributes feature will no longer remove existing attributes on the HTML tag
13098

131-
## 3.0.0
99+
# 3.0.0
132100

133-
Features:
101+
### Features
134102

135103
- innerHTML for scripts. Originally added to support the use of JSON-LD (https://developers.google.com/schemas/formats/json-ld?hl=en), but this can be used for any inline scripts you would like in your document head.
136104
- New htmlAttributes prop which allows users to add attributes to their html tag.
137105
- New defaultTitle prop which allows users to have a fallback title in the scenario where a Helmet wants to define a titleTemplate for it's nested routes, but not for itself (for example, at the root component level). See README for use cases.
138106

139-
Bugfixes:
107+
### Bugfixes
140108

141109
- Removed all polyfills from Helmet. Due to reported conflicts, to remove bloat, and to encourage users to polyfill at the application level. Please double-check that you weren't relying solely on Helmet for polyfilling certain features.
142110

143-
## 2.3.1
111+
# 2.3.1
144112

145-
Bugfixes:
113+
### Bugfixes
146114

147115
- Fallback values for rewind on the server threw a `tags.map` error in Node. Changing the tag default values to `[]` fixes it.
148116

149-
## 2.3.0
117+
# 2.3.0
150118

151-
Bugfixes:
119+
### Bugfixes
152120

153121
- FOUC fix - existing tags that persist between route changes, will not be removed and re-added to the DOM. They will remain unchanged. This will avoid, in particular, stylesheets being removed and re-added causing an unstyled flash when the new Helmet is rendered.
154122
- onChangeClientState enhanced to also return the html tags that were added and removed.
155123
- provide fallback object for rewind() result - If no Helmets are rendered, rewind() will still return head.base, head.title, etc.
156124
- Tag attributes ordering does not matter. It no longer looks at the first valid attribute to identify the tag. All attributes of the tag will be searched for names that can be found in HelmetConstants.js. When rel="canonical" is included, it will take priority over href.
157125
- Bump dependencies
158126

159-
## 2.2.0
127+
# 2.2.0
160128

161-
Features:
129+
### Features
162130

163131
- New prop `onChangeClientState` to set a callback function that is called in the event the DOM is changed by Helmet. When set on a Helmet, it will apply to all subsequent Helmet instances downstream (similar to titleTemplate).
164132

165-
Bugfixes:
133+
### Bugfixes
166134

167135
- Fix for double encoding when returning state to the server as React components.
168136
- dist -> lib
169137
- Added CLA url to CONTRIBUTING.
170138
- Added .babelrc to .npmignore (fix for now, as the settings were not compatible with Babel 6)
171139
- Bump dependencies (except Babel 6 as a dev dependency - coming soon)
172140

173-
## 2.1.1
141+
# 2.1.1
174142

175-
Bugfixes:
143+
### Bugfixes
176144

177145
- Remove npm he dependency
178146
- HTML entitiy encode only special characters instead of all characters that have HTML entity equivalents
179147

180-
## 2.1.0
148+
# 2.1.0
181149

182-
Features:
150+
### Features
183151

184152
- All head attributes (title / base / meta / link / script) returned with `.toComponent()` and `.toString()` methods to use in any scenario when calling rewind on the server.
185153
- Helmet using React 14 for unit testing.
186154

187-
Bugfixes:
155+
### Bugfixes
188156

189157
- Bump dependencies
190158

191-
## 2.0.0
159+
# 2.0.0
192160

193-
Features:
161+
### Features
194162

195163
- Base tag support.
196164
- Script tag support.
197165
- All head attributes (title / base / meta / link / script) returned as React components on the server with toString() support
198166
- Removed ability to nest children in Helmet.
199167
- Decorated component from react-side-effect, now wrapped by Helmet in order to enforce deep equal check on shouldComponentUpdate. This will limit unnecessary DOM changes and rendering.
200168

201-
Bugfixes:
169+
### Bugfixes
202170

203171
- Bump dependencies
204172

205-
## 1.1.5
173+
# 1.1.5
206174

207-
Bugfixes:
175+
### Bugfixes
208176

209177
- Adding webpack under devDependencies, as it's no longer automatically installed as a peer dependency
210178
- Bump dependencies
211179

212-
## 1.1.4
180+
# 1.1.4
213181

214-
Bugfixes:
182+
### Bugfixes
215183

216184
- Bumping to react-side-effect 1.0.2
217185
- Updating peer dependences for react 0.14.0-rc1
218186
- Bump dependencies
219187

220-
## 1.1.3
188+
# 1.1.3
221189

222-
Bugfixes:
190+
### Bugfixes
223191

224192
- Externalize react-side-effect
225193
- shouldComponentUpdate compares props with deep equal
@@ -229,40 +197,40 @@ Bugfixes:
229197
- Bumping to react-side-effect 1.0.1
230198
- Bump dependencies.
231199

232-
## 1.1.2
200+
# 1.1.2
233201

234-
Bugfixes:
202+
### Bugfixes
235203

236204
- Use named exports in HelmetConstants
237205
- Allow all React 0.14 betas in peer dependencies
238206
- Bump dependencies.
239207
- Fixed invariant check in CreateSideEffect
240208

241-
## 1.1.1
209+
# 1.1.1
242210

243-
Bugfixes:
211+
### Bugfixes
244212

245213
- Externalizing of React helpers - exenv, invariant, shallowequal
246214
- Using ES6 collections to manage tags
247215
- Bumping peer dependency for use in React 0.14.0-beta.
248216
- Title encoded when being rendered on the server
249217
- Import a smaller subset of core-js modules instead of the whole shim.
250218

251-
## 1.1.0
219+
# 1.1.0
252220

253-
Features:
221+
### Features
254222

255223
- titleTemplate attribute to help format `document.title`
256224

257-
Bugfixes:
225+
### Bugfixes
258226

259227
- Bump dependencies.
260228
- Title will never be overwritten with blank title. Lifts constraint where every component with Helmet needed to define a title.
261229
- Re-organization of unit tests.
262230

263-
## 1.0.1
231+
# 1.0.1
264232

265-
Bugfixes:
233+
### Bugfixes
266234

267235
- Bump dependencies
268236
- rewind() saves title/meta/link values before disposing
@@ -271,8 +239,8 @@ Bugfixes:
271239
- Added Travis CI integration
272240
- npm requirement removed - removed reference in README (System Requirements) and in package.json (engines)
273241

274-
## 1.0.0
242+
# 1.0.0
275243

276-
Features:
244+
### Features
277245

278246
- Initial release

package.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,9 @@
4949
"babel-preset-react": "^6.23.0",
5050
"chai": "^3.5.0",
5151
"codecov": "^2.1.0",
52+
"conventional-changelog-cli": "^1.3.1",
5253
"cross-env": "^3.2.4",
54+
"cz-conventional-changelog": "^2.0.0",
5355
"eslint": "^3.18.0",
5456
"eslint-config-nfl": "^11.1.0",
5557
"eslint-plugin-import": "^2.2.0",
@@ -79,14 +81,21 @@
7981
"webpack": "^2.2.1"
8082
},
8183
"scripts": {
84+
"changelog": "conventional-changelog -p angular -i CHANGELOG.md -s",
8285
"clean": "rimraf lib coverage es",
8386
"lint": "eslint --ignore-path .gitignore -- .",
8487
"test": "cross-env BABEL_ENV=test karma start karma.config.js",
8588
"posttest": "cat ./coverage/text.txt",
8689
"pretest": "npm run clean && npm run lint",
90+
"commit": "git-cz",
8791
"compile": "npm run compile:commonjs && npm run compile:es",
8892
"compile:commonjs": "cross-env BABEL_ENV=commonjs babel src --out-dir lib",
8993
"compile:es": "cross-env BABEL_ENV=es babel src --out-dir es --ignore test.js",
9094
"prepublish": "npm run compile"
95+
},
96+
"config": {
97+
"commitizen": {
98+
"path": "./node_modules/cz-conventional-changelog"
99+
}
91100
}
92101
}

0 commit comments

Comments
 (0)