Scoped: update more babel- to @babel/ [skip ci]
This commit is contained in:
parent
65495105e9
commit
696df10f51
@ -38,7 +38,7 @@ export const logEntryPolyfills = (
|
||||
if (!importPolyfillIncluded) {
|
||||
console.log(
|
||||
`
|
||||
[${filename}] \`import 'babel-polyfill'\` was not found.`,
|
||||
[${filename}] \`import '@babel/polyfill'\` was not found.`,
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
||||
@ -103,7 +103,7 @@ export default function({ types: t }: { types: Object }): Plugin {
|
||||
console.warn(
|
||||
`
|
||||
When setting \`useBuiltIns: 'usage'\`, polyfills are automatically imported when needed.
|
||||
Please remove the \`import 'babel-polyfill'\` call or use \`useBuiltIns: 'entry'\` instead.`,
|
||||
Please remove the \`import '@babel/polyfill'\` call or use \`useBuiltIns: 'entry'\` instead.`,
|
||||
);
|
||||
path.remove();
|
||||
}
|
||||
@ -115,7 +115,7 @@ export default function({ types: t }: { types: Object }): Plugin {
|
||||
console.warn(
|
||||
`
|
||||
When setting \`useBuiltIns: 'usage'\`, polyfills are automatically imported when needed.
|
||||
Please remove the \`require('babel-polyfill')\` call or use \`useBuiltIns: 'entry'\` instead.`,
|
||||
Please remove the \`require('@babel/polyfill')\` call or use \`useBuiltIns: 'entry'\` instead.`,
|
||||
);
|
||||
bodyPath.remove();
|
||||
}
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -17,5 +17,5 @@ Using plugins:
|
||||
|
||||
Using polyfills with `entry` option:
|
||||
|
||||
[src/in.js] `import 'babel-polyfill'` was not found.
|
||||
[src/in.js] `import '@babel/polyfill'` was not found.
|
||||
src/in.js -> lib/in.js
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1,2 +1,2 @@
|
||||
When setting `useBuiltIns: 'usage'`, polyfills are automatically imported when needed.
|
||||
Please remove the `import 'babel-polyfill'` call or use `useBuiltIns: 'entry'` instead.
|
||||
Please remove the `import '@babel/polyfill'` call or use `useBuiltIns: 'entry'` instead.
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1 +1 @@
|
||||
import 'babel-polyfill';
|
||||
import '@babel/polyfill';
|
||||
|
||||
@ -1,3 +1,3 @@
|
||||
if (parseInt(process.version.slice(1)) > 5) {
|
||||
require('babel-polyfill');
|
||||
require('@babel/polyfill');
|
||||
}
|
||||
|
||||
@ -110,7 +110,7 @@ export default class File {
|
||||
throw new Error(
|
||||
"This API has been removed. If you're looking for this " +
|
||||
"functionality in Babel 7, you should import the " +
|
||||
"'babel-helper-module-imports' module and use the functions exposed " +
|
||||
"'@babel/helper-module-imports' module and use the functions exposed " +
|
||||
" from that module, such as 'addNamed' or 'addDefault'.",
|
||||
);
|
||||
}
|
||||
|
||||
@ -13,8 +13,8 @@ npm install --save-dev babel-helpers
|
||||
Direct:
|
||||
|
||||
```js
|
||||
import * as helpers from 'babel-helpers';
|
||||
import * as t from 'babel-types';
|
||||
import * as helpers from '@babel/helpers';
|
||||
import * as t from '@babel/types';
|
||||
|
||||
const typeofHelper = helpers.get('typeof');
|
||||
|
||||
@ -44,7 +44,7 @@ Helpers are defined in the `src/helpers.js` file, and they must be valid modules
|
||||
- They must have a default export, which is their entry-point.
|
||||
- They can import other helpers, exclusively by using default imports.
|
||||
- They can't have named exports.
|
||||
|
||||
|
||||
```js
|
||||
helpers.customHelper = defineHelper(`
|
||||
import dep from "dependency";
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user