Skip to content

Commit 40bde1b

Browse files
authored
Update CHANGELOG.md
1 parent d61ca62 commit 40bde1b

File tree

1 file changed

+30
-15
lines changed

1 file changed

+30
-15
lines changed

CHANGELOG.md

Lines changed: 30 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,22 @@ It provides a high-level overview of new features and improvements. Now let's se
1212
Inside any created project that has not been ejected, run:
1313

1414
```bash
15-
$ npm install --save --save-exact [email protected]
16-
$ # or
17-
$ yarn add --exact [email protected]
15+
npm install --save --save-exact [email protected]
16+
```
17+
18+
or
19+
1820
```
21+
yarn add --exact [email protected]
22+
```
23+
24+
If you previously ejected but now want to upgrade, one common solution is to find the commits where you ejected (and any subsequent commits changing the configuration), revert them, upgrade, and later optionally eject again. It’s also possible that the feature you ejected for (maybe Sass or CSS Modules?) is now supported out of the box. You can find a list of notable new features in the **[Create React App 2.0 blog post](https://reactjs.org/blog/2018/10/01/create-react-app-v2.html)**.
25+
26+
## Breaking Changes
1927

20-
Like any major release, it contains a few breaking changes. We expect that they won't affect every users, but we provide them in detail below. We recommend to scan over these sections to see if something affects you. If we missed something, please file a new issue.
28+
Like any major release, `[email protected]` contains a few breaking changes. We expect that they won't affect every user, but we recommend to scan over these sections to see if something is relevant to you. If we missed something, please file a new issue.
2129

22-
## Breaking Change: IE 9, IE 10, and IE 11 are no longer supported by default (but you can opt in!)
30+
### IE 9, IE 10, and IE 11 are no longer supported by default (but you can opt in!)
2331

2432
We have dropped default support for Internet Explorer 9, 10, and 11. If you still need to support these browsers, follow the instructions below.
2533

@@ -40,7 +48,7 @@ import 'react-app-polyfill/ie11'; // For IE 11 support
4048

4149
You can read more about [these polyfills here](https://github.com/facebook/create-react-app/tree/master/packages/react-app-polyfill).
4250

43-
## Breaking Change: Dynamic `import()` of a CommonJS module now has a `.default` property
51+
### Dynamic `import()` of a CommonJS module now has a `.default` property
4452

4553
[Webpack 4 changed the behavior of `import()`](https://medium.com/webpack/webpack-4-import-and-commonjs-d619d626b655) to be closer in line with the specification.
4654

@@ -53,7 +61,7 @@ const throttle = await import('lodash/throttle');
5361
const throttle = await import('lodash/throttle').then(m => m.default);
5462
```
5563

56-
## Breaking Change: `require.ensure()` is superseded by dynamic `import()`
64+
### `require.ensure()` is superseded by dynamic `import()`
5765

5866
We previously allowed code splitting with a webpack-specific directive, `require.ensure()`. It is now disabled in favor of `import()`. To switch to `import()`, follow the examples below:
5967

@@ -86,7 +94,7 @@ Promise.all([import('module-a'), import('module-b')]).then(([a, b]) => {
8694
});
8795
```
8896

89-
## Breaking Change: The default Jest environment was changed to `jsdom`
97+
### The default Jest environment was changed to `jsdom`
9098

9199
Look at the `test` entry in the `scripts` section of your `package.json`.
92100
Here's a table how to change it from "before" and "after", depending on what you have there:
@@ -97,7 +105,7 @@ Here's a table how to change it from "before" and "after", depending on what you
97105
| `react-scripts test` | `react-scripts test --env=node` |
98106

99107

100-
## Breaking Change: Move advanced proxy configuration to `src/setupProxy.js`
108+
### Object `proxy` configuration is superseded by `src/setupProxy.js`
101109

102110
To check if action is required, look for the `proxy` key in `package.json` and follow this table:
103111

@@ -115,9 +123,13 @@ If your `proxy` is an object, that means you are using the advanced proxy config
115123
First, install `http-proxy-middleware` using npm or Yarn:
116124

117125
```bash
118-
$ npm install http-proxy-middleware --save
119-
$ # or
120-
$ yarn add http-proxy-middleware
126+
npm install http-proxy-middleware
127+
```
128+
129+
or
130+
131+
```
132+
yarn add http-proxy-middleware
121133
```
122134

123135
Next, create `src/setupProxy.js` and place the following contents in it:
@@ -156,14 +168,17 @@ module.exports = function(app) {
156168

157169
You can also use completely custom logic there now! This wasn't possible before.
158170

159-
## Breaking Change: `.mjs` file extension support was removed
171+
### `.mjs` file extension support is removed
160172

161173
Change the extension of any files in your project using `.mjs` to just `.js`.
162174

163175
It was removed because of inconsistent support from underlying tools. We will add it back after it stops being experimental, and Jest gets built-in support for it.
164176

177+
### `PropTypes` definitions are now removed in production
178+
179+
Normally, this shouldn't affect your logic and should make the resulting bundle smaller. However, you may be relying on PropTypes definition for production logic. This is not recommended, and will break now. If a library does it, one possible solution is to file an issue in it with a proposal to use a different field (not `propTypes`) to signal that the declaration needs to be retained.
165180

166-
## **Anything missing?**
181+
### Anything missing?
167182

168183
This was a large release, and we might have missed something.
169184

@@ -173,7 +188,7 @@ Please [file an issue](https://github.com/facebook/create-react-app/issues/new)
173188

174189
If you used 2.x alphas, please [follow these instructions](https://gist.github.com/gaearon/8650d1c70e436e5eff01f396dffc4114).
175190

176-
### Detailed Changelog
191+
# Detailed Changelog
177192

178193
**For a readable summary of the changes, [check out our blog post](https://reactjs.org/blog/2018/10/01/create-react-app-v2.html).**
179194

0 commit comments

Comments
 (0)