-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Switch to Babel 7 #3522
Switch to Babel 7 #3522
Changes from 28 commits
7a07a1a
7cbeb83
b0ba884
5cb193c
ae2b569
222a905
f9391f7
fbaacf4
0cdf4f9
dc15217
60a42ae
911debc
8003d54
c180b49
eff7257
ca7516d
482abf2
539e46a
60a5f57
67ca211
60ab887
95dbd6f
dea535e
1466478
ab26521
fb6480d
f95e5a9
7f29d27
44d93ab
b81c25f
174ddf5
9f504c2
4ade5c3
9537092
a29c74d
effe64a
0d5043d
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,24 @@ module.exports = { | |
rules: [ | ||
{ | ||
test: /\.js$/, | ||
include: path.resolve(__dirname, './src'), | ||
include: [ | ||
path.resolve(__dirname, './src'), | ||
path.dirname( | ||
require.resolve('chalk', { | ||
paths: path.dirname(require.resolve('@babel/code-frame')), | ||
}) | ||
), | ||
path.dirname( | ||
require.resolve( | ||
'ansi-styles', | ||
path.dirname( | ||
require.resolve('chalk', { | ||
paths: path.dirname(require.resolve('@babel/code-frame')), | ||
}) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. All of this looks very fragile, why did we add it? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh, okay. #3522 (comment) sigh There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It should be pretty reliable -- it resolves Same for Alternatively, we can just always compile those modules. |
||
) | ||
) | ||
), | ||
], | ||
use: 'babel-loader', | ||
}, | ||
], | ||
|
This file was deleted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You might want to use
import { codeFrameColumns } from '@babel/code-frame';
, see https://www.npmjs.com/package/@babel/code-frame#upgrading-from-prior-versions