Skip to content

Commit bdc1366

Browse files
author
matar
committed
* 'master' of https://github.com/facebookincubator/create-react-app: (36 commits) Publish Changelog for 1.0.12 (facebook#3016) Relax React dep requirements Default Favicon lossless optimisation (facebook#2917) update babel-runtime dependency in react-error-overlay and react-scripts (facebook#2991) Convert react-error-overlay to React (facebook#2515) Bump react-dev-utils Fix module function name in error overlay (facebook#3012) Docs: debugging in WebStorm (facebook#2986) Fix docs for `printFileSizesAfterBuild` (facebook#2942) Remove Modulus from user guide (facebook#2948) Remove superfluous lodash usage (facebook#2938) Update README.md (facebook#2927) Publish Prepare for 1.0.11 release (facebook#2924) Update dev deps (facebook#2923) Update README.md Use env variable to disable source maps (facebook#2818) Make formatWebpackMessages return all messages (facebook#2834) Adjust the `checkIfOnline` check if in a corporate proxy environment (facebook#2884) ...
2 parents e62e2b2 + a51be95 commit bdc1366

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+1657
-1564
lines changed

CHANGELOG.md

+179-4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,178 @@
1+
## 1.0.12 (August 28, 2017)
2+
3+
#### :bug: Bug Fix
4+
5+
* `react-error-overlay`
6+
* [#3012](https://github.com/facebookincubator/create-react-app/pull/3012) Fix module function name in error overlay. ([@gaearon](https://github.com/gaearon))
7+
8+
* `react-dev-utils`
9+
* [#2938](https://github.com/facebookincubator/create-react-app/pull/2938) Remove superfluous lodash usage. ([@Timer](https://github.com/Timer))
10+
11+
#### :nail_care: Enhancement
12+
13+
* `react-scripts`
14+
15+
* [#2917](https://github.com/facebookincubator/create-react-app/pull/2917) Optimize the size of default favicon. ([@sylvainbaronnet](https://github.com/sylvainbaronnet))
16+
17+
#### :memo: Documentation
18+
19+
* `react-scripts`
20+
21+
* [#2986](https://github.com/facebookincubator/create-react-app/pull/2986) Docs: debugging in WebStorm. ([@prigara](https://github.com/prigara))
22+
* [#2948](https://github.com/facebookincubator/create-react-app/pull/2948) Remove Modulus from user guide. ([@Zertz](https://github.com/Zertz))
23+
* [#2927](https://github.com/facebookincubator/create-react-app/pull/2927) Update README.md. ([@tbassetto](https://github.com/tbassetto))
24+
25+
* `react-dev-utils`
26+
27+
* [#2942](https://github.com/facebookincubator/create-react-app/pull/2942) Fix docs for `printFileSizesAfterBuild`. ([@Kerumen](https://github.com/Kerumen))
28+
29+
#### :house: Internal
30+
31+
* `react-error-overlay`, `react-scripts`
32+
33+
* [#2991](https://github.com/facebookincubator/create-react-app/pull/2991) Update `babel-runtime` dependency ([@christophehurpeau](https://github.com/christophehurpeau))
34+
35+
* `react-dev-utils`, `react-error-overlay`, `react-scripts`
36+
37+
* [#2515](https://github.com/facebookincubator/create-react-app/pull/2515) Convert `react-error-overlay` to React ([@tharakawj](https://github.com/tharakawj))
38+
39+
#### Committers: 9
40+
41+
- Christophe Hurpeau ([christophehurpeau](https://github.com/christophehurpeau))
42+
- Dan Abramov ([gaearon](https://github.com/gaearon))
43+
- Ekaterina Prigara ([prigara](https://github.com/prigara))
44+
- Joe Haddad ([Timer](https://github.com/Timer))
45+
- Pier-Luc Gendreau ([Zertz](https://github.com/Zertz))
46+
- Sylvain Baronnet ([sylvainbaronnet](https://github.com/sylvainbaronnet))
47+
- Tharaka Wijebandara ([tharakawj](https://github.com/tharakawj))
48+
- Thomas Bassetto ([tbassetto](https://github.com/tbassetto))
49+
- Yann Pringault ([Kerumen](https://github.com/Kerumen))
50+
51+
### Migrating from 1.0.11 to 1.0.12
52+
53+
Inside any created project that has not been ejected, run:
54+
55+
```
56+
npm install --save --save-exact [email protected]
57+
```
58+
59+
or
60+
61+
```
62+
yarn add --exact [email protected]
63+
```
64+
65+
## 1.0.11 (August 9, 2017)
66+
67+
#### :bug: Bug Fix
68+
* `create-react-app`
69+
* [#2884](https://github.com/facebookincubator/create-react-app/pull/2884) Improve offline heuristic for proxied environments. ([@bsyk](https://github.com/bsyk))
70+
71+
When a Yarn proxy is set, we will check its connectivity if we cannot reach Yarn's registry. This is often the case when DNS lookups must be made through the proxy.
72+
73+
* [#2853](https://github.com/facebookincubator/create-react-app/pull/2853) Allow use of scoped packages with a pinned version. ([@wileybenet](https://github.com/wileybenet))
74+
* `react-dev-utils`
75+
* [#2796](https://github.com/facebookincubator/create-react-app/pull/2796) Properly escape HTML tags in error overlay. ([@ccloli](https://github.com/ccloli))
76+
77+
Elements printed in their entirety would sometimes render as HTML. This should no longer happen and should properly render as text.
78+
79+
* `react-dev-utils`, `react-scripts`
80+
* [#2834](https://github.com/facebookincubator/create-react-app/pull/2834) Make `formatWebpackMessages` return all messages ([@onigoetz](https://github.com/onigoetz))
81+
* `react-scripts`
82+
* [#2806](https://github.com/facebookincubator/create-react-app/pull/2806) Fix SockJS version compatibility. ([@christianbundy](https://github.com/christianbundy))
83+
* [#2738](https://github.com/facebookincubator/create-react-app/pull/2738) Fix Jest `node` file resolution. ([@mostafah](https://github.com/mostafah))
84+
85+
#### :nail_care: Enhancement
86+
* `react-scripts`
87+
* [#2818](https://github.com/facebookincubator/create-react-app/pull/2818) Allow sourcemaps to be disabled. ([@viankakrisna](https://github.com/viankakrisna))
88+
89+
As applications grow more complex, it is possible webpack may run out of memory while generating source maps. They may now be disabled by setting `GENERATE_SOURCEMAP=false`.
90+
91+
* [#2913](https://github.com/facebookincubator/create-react-app/pull/2913) Allow flags to be passed to node when running `react-scripts`. ([@koistya](https://github.com/koistya))
92+
* [#2574](https://github.com/facebookincubator/create-react-app/pull/2574) Upgrade to `webpack@3`. ([@themre](https://github.com/themre))
93+
* [#2747](https://github.com/facebookincubator/create-react-app/pull/2747) Simplify webpack configuration using `Rule.oneOf`. ([@Furizaa](https://github.com/Furizaa))
94+
* `react-dev-utils`, `react-scripts`
95+
* [#2468](https://github.com/facebookincubator/create-react-app/pull/2468) Allow importing `package.json`. ([@iamdoron](https://github.com/iamdoron))
96+
* [#2650](https://github.com/facebookincubator/create-react-app/pull/2650) Make UglifyJS error friendlier. ([@viankakrisna](https://github.com/viankakrisna))
97+
* `create-react-app`
98+
* [#2785](https://github.com/facebookincubator/create-react-app/pull/2785) Change error wording and list conflicting files when initializing app. ([@OwenFlood](https://github.com/OwenFlood))
99+
* `react-dev-utils`
100+
* [#2761](https://github.com/facebookincubator/create-react-app/pull/2761) Don't prompt to install serve if already installed. ([@OwenFlood](https://github.com/OwenFlood))
101+
* [#2754](https://github.com/facebookincubator/create-react-app/pull/2754) Auto-detect JetBrains IDEs. ([@danrr](https://github.com/danrr))
102+
* [#2740](https://github.com/facebookincubator/create-react-app/pull/2740) Support PyCharm in `launchEditor`. ([@danrr](https://github.com/danrr))
103+
* [#2723](https://github.com/facebookincubator/create-react-app/pull/2723) Reorder vim arguments in `launchEditor` so `--remote` works. ([@trygveaa](https://github.com/trygveaa))
104+
* `eslint-config-react-app`, `react-scripts`
105+
* [#2735](https://github.com/facebookincubator/create-react-app/pull/2735) Upgrade to `eslint@4`. ([@trungdq88](https://github.com/trungdq88))
106+
* `eslint-config-react-app`
107+
* [#2701](https://github.com/facebookincubator/create-react-app/pull/2701) Set `allowTaggedTemplates` to true (eslint). ([@denkristoffer](https://github.com/denkristoffer))
108+
109+
#### :memo: Documentation
110+
* Other
111+
* [#2728](https://github.com/facebookincubator/create-react-app/pull/2728) Add Electrode to alternatives. ([@animesh10](https://github.com/animesh10))
112+
* [#2788](https://github.com/facebookincubator/create-react-app/pull/2788) Update link for motion. ([@viankakrisna](https://github.com/viankakrisna))
113+
* [#2697](https://github.com/facebookincubator/create-react-app/pull/2697) Fix env list ordering. ([@alexeyraspopov](https://github.com/alexeyraspopov))
114+
* `react-dev-utils`
115+
* [#2798](https://github.com/facebookincubator/create-react-app/pull/2798) Update note about `webpackHotDevClient` support. ([@ForbesLindesay](https://github.com/ForbesLindesay))
116+
* `react-scripts`
117+
* [#2822](https://github.com/facebookincubator/create-react-app/pull/2822) Add explicit "Opting Out of Caching" header. ([@gaearon](https://github.com/gaearon))
118+
* [#2725](https://github.com/facebookincubator/create-react-app/pull/2725) Fixed typo. ([@zeel](https://github.com/zeel))
119+
* [#2668](https://github.com/facebookincubator/create-react-app/pull/2668) Document `basename` feature in `react-router`. ([@viankakrisna](https://github.com/viankakrisna))
120+
* [#2719](https://github.com/facebookincubator/create-react-app/pull/2719) Remove Windows note for `source-map-explorer`. ([@hodanny](https://github.com/hodanny))
121+
* `babel-preset-react-app`
122+
* [#2732](https://github.com/facebookincubator/create-react-app/pull/2732) Update link to issue blocking JSX hoisting. ([@ForbesLindesay](https://github.com/ForbesLindesay))
123+
124+
#### :house: Internal
125+
* `create-react-app`, `eslint-config-react-app`, `react-dev-utils`, `react-error-overlay`, `react-scripts`
126+
* [#2923](https://github.com/facebookincubator/create-react-app/pull/2923) Update deps. ([@Timer](https://github.com/Timer))
127+
* `eslint-config-react-app`
128+
* [#2718](https://github.com/facebookincubator/create-react-app/pull/2718) Re-enable flowtype warning. ([@oskarkook](https://github.com/oskarkook))
129+
* Other
130+
* [#2700](https://github.com/facebookincubator/create-react-app/pull/2700) Unstage `yarn.lock` pre-commit. ([@jdcrensh](https://github.com/jdcrensh))
131+
* `react-scripts`
132+
* [#2873](https://github.com/facebookincubator/create-react-app/pull/2873) Use template strings. ([@monkindey](https://github.com/monkindey))
133+
134+
#### Committers: 26
135+
- 864907600cc ([ccloli](https://github.com/ccloli))
136+
- Ade Viankakrisna Fadlil ([viankakrisna](https://github.com/viankakrisna))
137+
- Alexey Raspopov ([alexeyraspopov](https://github.com/alexeyraspopov))
138+
- Andreas Hoffmann ([Furizaa](https://github.com/Furizaa))
139+
- Animesh Dutta ([animesh10](https://github.com/animesh10))
140+
- Ben Sykes ([bsyk](https://github.com/bsyk))
141+
- Christian Bundy ([christianbundy](https://github.com/christianbundy))
142+
- Dan Abramov ([gaearon](https://github.com/gaearon))
143+
- Dan Ristea ([danrr](https://github.com/danrr))
144+
- Danny Ho ([hodanny](https://github.com/hodanny))
145+
- Forbes Lindesay ([ForbesLindesay](https://github.com/ForbesLindesay))
146+
- Joe Haddad ([Timer](https://github.com/Timer))
147+
- Jon Crenshaw ([jdcrensh](https://github.com/jdcrensh))
148+
- Kiho · Cham ([monkindey](https://github.com/monkindey))
149+
- Konstantin Tarkus ([koistya](https://github.com/koistya))
150+
- Kristoffer ([denkristoffer](https://github.com/denkristoffer))
151+
- Mostafa Hajizadeh ([mostafah](https://github.com/mostafah))
152+
- Oskar Köök ([oskarkook](https://github.com/oskarkook))
153+
- Owen Flood ([OwenFlood](https://github.com/OwenFlood))
154+
- Stéphane Goetz ([onigoetz](https://github.com/onigoetz))
155+
- Trygve Aaberge ([trygveaa](https://github.com/trygveaa))
156+
- Wiley Bennett ([wileybenet](https://github.com/wileybenet))
157+
- [iamdoron](https://github.com/iamdoron)
158+
- [themre](https://github.com/themre)
159+
- zeel ([zeel](https://github.com/zeel))
160+
- Đinh Quang Trung ([trungdq88](https://github.com/trungdq88))
161+
162+
### Migrating from 1.0.10 to 1.0.11
163+
164+
Inside any created project that has not been ejected, run:
165+
166+
```
167+
npm install --save --save-exact [email protected]
168+
```
169+
170+
or
171+
172+
```
173+
yarn add --exact [email protected]
174+
```
175+
1176
## 1.0.10 (June 29, 2017)
2177

3178
#### :bug: Bug Fix
@@ -110,7 +285,7 @@ yarn add --exact [email protected]
110285
* [#2600](https://github.com/facebookincubator/create-react-app/pull/2600) Add empty mock for `dgram` Node module. ([@micopiira](https://github.com/micopiira))
111286
* [#2458](https://github.com/facebookincubator/create-react-app/pull/2458) Add names to module factories in development. ([@Zaccc123](https://github.com/Zaccc123))
112287
* [#2551](https://github.com/facebookincubator/create-react-app/pull/2551) In new projects, unregister service worker and force reload if `service-worker.js` is not found. ([@ro-savage](https://github.com/ro-savage))
113-
288+
114289
* `babel-preset-react-app`, `react-dev-utils`, `react-scripts`
115290

116291
* [#2658](https://github.com/facebookincubator/create-react-app/pull/2658) Bump dependencies. ([@gaearon](https://github.com/gaearon))
@@ -119,7 +294,7 @@ yarn add --exact [email protected]
119294

120295
* [#2657](https://github.com/facebookincubator/create-react-app/pull/2657) Put `react-scripts` in `dependencies`, not `devDependencies`. ([@gaearon](https://github.com/gaearon))
121296
* [#2635](https://github.com/facebookincubator/create-react-app/pull/2635) Silence unhelpful npm warnings. ([@gaearon](https://github.com/gaearon))
122-
297+
123298
* `react-dev-utils`
124299

125300
* [#2637](https://github.com/facebookincubator/create-react-app/pull/2637) Auto-detect Brackets editor from error overlay. ([@petetnt](https://github.com/petetnt))
@@ -176,7 +351,7 @@ yarn add --exact [email protected]
176351
* [#2397](https://github.com/facebookincubator/create-react-app/pull/2397) Fix command in e2e-kitchensink.sh cleanup. ([@ro-savage](https://github.com/ro-savage))
177352
* [#2388](https://github.com/facebookincubator/create-react-app/pull/2388) Fix wrong path expansion in end-to-end test. ([@gaearon](https://github.com/gaearon))
178353
* [#2387](https://github.com/facebookincubator/create-react-app/pull/2387) Catch "No tests found" during CI. ([@EnoahNetzach](https://github.com/EnoahNetzach))
179-
354+
180355
* `react-scripts`
181356

182357
* [#2408](https://github.com/facebookincubator/create-react-app/pull/2408) E2E testing enhancements. ([@EnoahNetzach](https://github.com/EnoahNetzach))
@@ -573,7 +748,7 @@ yarn add --dev --exact [email protected]
573748

574749
We’ve been working on this release for the past few months, and there are many big impovements, from migrating to webpack 2 to a brand new runtime error overlay and built-in support for Progressive Web Apps.
575750

576-
So instead of just enumerating them here, we decided to write a blog post about all the new features.
751+
So instead of just enumerating them here, we decided to write a blog post about all the new features.<br>
577752
Check it out: **[What’s New in Create React App](https://facebook.github.io/react/blog/2017/05/18/whats-new-in-create-react-app.html)**.
578753

579754
Have you read it? Now let's see how to update your app to the latest version.

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,7 @@ Some of the more popular and actively maintained ones are:
239239
* [NYTimes/kyt](https://github.com/NYTimes/kyt)
240240
* [zeit/next.js](https://github.com/zeit/next.js)
241241
* [gatsbyjs/gatsby](https://github.com/gatsbyjs/gatsby)
242+
* [electrode-io/electrode](https://github.com/electrode-io/electrode)
242243

243244
Notable alternatives also include:
244245

lerna.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"lerna": "2.0.0-rc.5",
2+
"lerna": "2.0.0",
33
"version": "independent",
44
"changelog": {
55
"repo": "facebookincubator/create-react-app",

package.json

+6-3
Original file line numberDiff line numberDiff line change
@@ -14,17 +14,20 @@
1414
"precommit": "lint-staged"
1515
},
1616
"devDependencies": {
17-
"eslint": "3.19.0",
17+
"eslint": "^4.4.1",
1818
"husky": "^0.13.2",
19-
"lerna": "2.0.0-rc.5",
20-
"lerna-changelog": "^0.2.3",
19+
"lerna": "^2.0.0",
20+
"lerna-changelog": "^0.6.0",
2121
"lint-staged": "^3.3.1",
2222
"prettier": "^1.5.2"
2323
},
2424
"lint-staged": {
2525
"*.js": [
2626
"prettier --trailing-comma es5 --single-quote --write",
2727
"git add"
28+
],
29+
"yarn.lock": [
30+
"git rm --cached"
2831
]
2932
}
3033
}

packages/babel-preset-react-app/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "babel-preset-react-app",
3-
"version": "3.0.1",
3+
"version": "3.0.2",
44
"description": "Babel preset used by Create React App",
55
"repository": "facebookincubator/create-react-app",
66
"license": "BSD-3-Clause",

packages/create-react-app/createReactApp.js

+12-3
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ const semver = require('semver');
4747
const dns = require('dns');
4848
const tmp = require('tmp');
4949
const unpack = require('tar-pack').unpack;
50+
const url = require('url');
5051
const hyperquest = require('hyperquest');
5152

5253
const packageJson = require('./package.json');
@@ -440,8 +441,8 @@ function getPackageName(installPackage) {
440441
// Pull package name out of git urls e.g:
441442
// git+https://github.com/mycompany/react-scripts.git
442443
// git+ssh://github.com/mycompany/react-scripts.git#v1.2.3
443-
return Promise.resolve(installPackage.match(/([^\/]+)\.git(#.*)?$/)[1]);
444-
} else if (installPackage.indexOf('@') > 0) {
444+
return Promise.resolve(installPackage.match(/([^/]+)\.git(#.*)?$/)[1]);
445+
} else if (installPackage.match(/.+@/)) {
445446
// Do not match @scope/ when stripping off @version or @tag
446447
return Promise.resolve(
447448
installPackage.charAt(0) + installPackage.substr(1).split('@')[0]
@@ -614,7 +615,15 @@ function checkIfOnline(useYarn) {
614615

615616
return new Promise(resolve => {
616617
dns.lookup('registry.yarnpkg.com', err => {
617-
resolve(err === null);
618+
if (err != null && process.env.https_proxy) {
619+
// If a proxy is defined, we likely can't resolve external hostnames.
620+
// Try to resolve the proxy name as an indication of a connection.
621+
dns.lookup(url.parse(process.env.https_proxy).hostname, proxyErr => {
622+
resolve(proxyErr == null);
623+
});
624+
} else {
625+
resolve(err == null);
626+
}
618627
});
619628
});
620629
}

packages/create-react-app/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "create-react-app",
3-
"version": "1.3.3",
3+
"version": "1.4.0",
44
"keywords": [
55
"react"
66
],

packages/eslint-config-react-app/index.js

+1-2
Original file line numberDiff line numberDiff line change
@@ -291,8 +291,7 @@ module.exports = {
291291

292292
// https://github.com/gajus/eslint-plugin-flowtype
293293
'flowtype/define-flow-type': 'warn',
294-
// TODO: Reenable once https://github.com/gajus/eslint-plugin-flowtype/issues/165 is fixed
295-
//'flowtype/require-valid-file-annotation': 'warn',
294+
'flowtype/require-valid-file-annotation': 'warn',
296295
'flowtype/use-flow-type': 'warn',
297296
},
298297
};
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "eslint-config-react-app",
3-
"version": "1.0.5",
3+
"version": "2.0.0",
44
"description": "ESLint configuration used by Create React App",
55
"repository": "facebookincubator/create-react-app",
66
"license": "BSD-3-Clause",
@@ -13,9 +13,9 @@
1313
"peerDependencies": {
1414
"babel-eslint": "^7.2.3",
1515
"eslint": "^4.1.1",
16-
"eslint-plugin-flowtype": "^2.33.0",
17-
"eslint-plugin-import": "^2.2.0",
18-
"eslint-plugin-jsx-a11y": "^5.0.3",
19-
"eslint-plugin-react": "^7.0.1"
16+
"eslint-plugin-flowtype": "^2.34.1",
17+
"eslint-plugin-import": "^2.6.0",
18+
"eslint-plugin-jsx-a11y": "^5.1.1",
19+
"eslint-plugin-react": "^7.1.0"
2020
}
2121
}

packages/react-dev-utils/ModuleScopePlugin.js

+10-8
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,9 @@ const chalk = require('chalk');
1313
const path = require('path');
1414

1515
class ModuleScopePlugin {
16-
constructor(appSrc) {
16+
constructor(appSrc, allowedFiles = []) {
1717
this.appSrc = appSrc;
18+
this.allowedFiles = new Set(allowedFiles);
1819
}
1920

2021
apply(resolver) {
@@ -40,15 +41,16 @@ class ModuleScopePlugin {
4041
if (relative.startsWith('../') || relative.startsWith('..\\')) {
4142
return callback();
4243
}
43-
// Find path from src to the requested file
44-
const requestRelative = path.relative(
45-
appSrc,
46-
path.resolve(
47-
path.dirname(request.context.issuer),
48-
request.__innerRequest_request
49-
)
44+
const requestFullPath = path.resolve(
45+
path.dirname(request.context.issuer),
46+
request.__innerRequest_request
5047
);
48+
if (this.allowedFiles.has(requestFullPath)) {
49+
return callback();
50+
}
51+
// Find path from src to the requested file
5152
// Error if in a parent directory of src/
53+
const requestRelative = path.relative(appSrc, requestFullPath);
5254
if (
5355
requestRelative.startsWith('../') ||
5456
requestRelative.startsWith('..\\')

0 commit comments

Comments
 (0)