Skip to content
This repository was archived by the owner on Jan 26, 2019. It is now read-only.

Commit b072857

Browse files
committed
Update react-dev-utils
1 parent 0d43626 commit b072857

File tree

4 files changed

+33
-3
lines changed

4 files changed

+33
-3
lines changed

packages/react-dev-utils/WebpackDevServerUtils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ function createCompiler(webpack, config, appName, urls, useYarn) {
183183
);
184184
console.log(
185185
'To ignore, add ' +
186-
chalk.cyan('// tslint:disable-next-line') +
186+
chalk.cyan('// eslint-disable-next-line') +
187187
' to the line before.\n'
188188
);
189189
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/**
2+
* Copyright (c) 2015-present, Facebook, Inc.
3+
*
4+
* This source code is licensed under the MIT license found in the
5+
* LICENSE file in the root directory of this source tree.
6+
*/
7+
'use strict';
8+
9+
const launchEditor = require('./launchEditor');
10+
const launchEditorEndpoint = require('./launchEditorEndpoint');
11+
12+
module.exports = function createLaunchEditorMiddleware() {
13+
return function launchEditorMiddleware(req, res, next) {
14+
if (req.url.startsWith(launchEditorEndpoint)) {
15+
launchEditor(req.query.fileName, req.query.lineNumber);
16+
res.end();
17+
} else {
18+
next();
19+
}
20+
};
21+
};
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
/**
2+
* Copyright (c) 2015-present, Facebook, Inc.
3+
*
4+
* This source code is licensed under the MIT license found in the
5+
* LICENSE file in the root directory of this source tree.
6+
*/
7+
'use strict';
8+
9+
// TODO: we might want to make this injectable to support DEV-time non-root URLs.
10+
module.exports = '/__open-stack-frame-in-editor';

packages/react-scripts/package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
"postcss-loader": "2.0.8",
3838
"promise": "8.0.1",
3939
"raf": "3.4.0",
40-
"react-dev-utils": "^4.2.1",
40+
"react-dev-utils": "4.2.1",
4141
"style-loader": "0.19.0",
4242
"ts-jest": "^20.0.7",
4343
"ts-loader": "^2.3.7",
@@ -61,4 +61,3 @@
6161
"fsevents": "1.1.2"
6262
}
6363
}
64-

0 commit comments

Comments
 (0)