Justin Ridgewell
e2244c92d9
Remove lodash from @babel/node tests ( #13025 )
2021-03-19 15:53:13 +01:00
Justin Ridgewell
830a93cc97
Remove lodash/chunk ( #13022 )
2021-03-19 15:52:25 +01:00
Justin Ridgewell
d12f9a98c7
Remove lodash/pull ( #13026 )
2021-03-19 15:51:34 +01:00
Justin Ridgewell
78cf07767a
Remove lodash/has ( #13023 )
2021-03-19 15:50:52 +01:00
Huáng Jùnliàng
020c88e74b
Update compat data ( #13008 )
2021-03-19 08:33:59 -04:00
Bogdan Savluk
d1f3d30598
convert @babel/helper-member-expression-to-functions to ts ( #12925 )
2021-03-19 12:53:21 +01:00
Sosuke Suzuki
beb7cf8b24
Sort error keys with ESLint ( #13020 )
2021-03-18 21:01:57 +01:00
Bogdan Savluk
21e8e59f7d
convert @babel/helper-module-imports to typescript ( #12924 )
2021-03-18 16:05:44 +01:00
Bogdan Savluk
ff8e9f74d8
convert @babel/helper-transform-fixture-test-runner to typescript ( #12923 )
...
* babel-helper-transform-fixture-test-runner flowts rename
* babel-helper-transform-fixture-test-runner flowts convert
* babel-helper-transform-fixture-test-runner
* babel-helper-transform-fixture-test-runner eslint fixes
* babel-helper-transform-fixture-test-runner type fix
* babel-helper-transform-fixture-test-runner
* yarn install
2021-03-18 10:52:19 -04:00
Bogdan Savluk
b97a627964
convert @babel/helper-simple-access to typescript ( #12927 )
2021-03-16 15:31:59 +01:00
Bogdan Savluk
befa46567f
convert @babel/helper-replace-supers to typescript ( #12926 )
2021-03-16 13:05:15 +01:00
hajnalbendeguz
281acd6448
Improve error message when not providing a value for JSX key ( #12983 )
...
* Improve error message when not providing a value for key
* Update packages/babel-plugin-transform-react-jsx/src/create-plugin.js
Show location of attribute instead of only the path
Co-authored-by: Huáng Jùnliàng <jlhwung@gmail.com>
* Change error message to be less aggressive
* Throw error when runtime is "classic"
Co-authored-by: Huáng Jùnliàng <jlhwung@gmail.com>
2021-03-16 13:02:08 +01:00
Babel Bot
4b674ea031
v7.13.11
2021-03-15 09:34:23 +00:00
Nicolò Ribaudo
759f8ecdce
Point to CJS files in @babel/compat-data's exports ( #13000 )
2021-03-15 10:14:47 +01:00
Huáng Jùnliàng
0988c471e9
Parse type imports in TSImportEqualsDeclaration ( #12962 )
2021-03-14 23:34:49 +01:00
Huáng Jùnliàng
1a05b81387
Support multiple static blocks ( #12738 )
2021-03-12 23:29:55 +01:00
Huáng Jùnliàng
71417bbfcf
Fix esmodule: "intersect" on iOS versions ( #12996 )
2021-03-12 22:14:00 +01:00
Nicolò Ribaudo
8ad6b75cde
Use function rather than var to compile private methods ( #12990 )
2021-03-11 02:08:31 +01:00
Babel Bot
d1d404b9a3
v7.13.10
2021-03-08 22:23:36 +00:00
Justin Ridgewell
49a9b70cb1
Optionally enable external-helpers in tests ( #12982 )
...
* Optionally enable external-helpers in tests
https://github.com/babel/babel/pull/12911 was a breaking change that now requires you to keep `babel-plugin-external-helpers` in your `package.json`. It'll will probably be unnoticeable for most, because another dependency could transitively depend on it, but AMP recently hit it when cleaning up our deps.
* Cast to boolean
* Fix package name
2021-03-08 16:58:30 -05:00
Nicolò Ribaudo
c702895256
Update min Babel version for #12917 ( #12977 )
2021-03-07 21:09:05 +01:00
Nicolò Ribaudo
8dacf85859
Lazily initialize and cache constant JSX elements ( #12967 )
...
Co-authored-by: Justin Ridgewell <justin@ridgewell.name>
2021-03-06 17:33:43 +01:00
Nicolò Ribaudo
d04842a700
Avoid using CJS globals in internal source files ( #12963 )
...
* Lint against CJS globals in modules
* Use `import.meta.url` instead of `__filename` in `src` files
* Prepare fixtures runner for `import.meta.url`
* Use `import.meta.url` instead of `__filename` in `test/index` files
* Remove `__dirname` from remaining test files
dirname
* Avoid using `module` in `src` files
* Avoid using `require` in `src` files
* Avoid using `require` in `test` files
* Update `@types/node`
* Compile dynamic import in `@babel/node`
* Fix windows
* Use `@babel/plugin-proposal-dynamic-import` from npm
2021-03-05 19:55:36 +01:00
Nicolò Ribaudo
5f60bf0d14
Regenerate @babel/runtime-* package.json ( #12964 )
2021-03-04 19:18:57 +01:00
Nicolò Ribaudo
d9ebfab07f
[internal] Use the Node.js behavior for default imports ( #12795 )
2021-03-04 13:55:15 +01:00
Huáng Jùnliàng
ac758f7d70
Ensure static private method init run before static property ( #12918 )
2021-03-04 00:02:23 +01:00
Huáng Jùnliàng
bdb207cb75
Class static private field destructure set ( #12917 )
...
* fix: support static private field destructure set ([C.#p] = [0])
* 🚧
* fix: add compatibility warning for older @babel/helper versions
* refactor: extract common routines among classPrivateFiled helpers
* More 🚧
2021-03-03 16:38:16 -05:00
Huáng Jùnliàng
70c77e550c
check descriptor before private field access ( #12910 )
...
* fix: check descriptor before private field access
* add test cases
2021-03-03 15:06:38 -05:00
Nicolò Ribaudo
42752a430e
Don't show warning from spied console.warn ( #12946 )
2021-03-02 15:22:20 +01:00
Sosuke Suzuki
b416847b61
(ts) Raise syntax error for abstract methods with a body ( #12687 )
...
Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>
2021-03-02 11:57:58 +01:00
Nicolò Ribaudo
0d9ad433b4
Fix esmodules: true without specified browsers ( #12908 )
...
* Fix `esmodules: true` without specified browsers
* fix
2021-03-02 08:16:25 +01:00
Huáng Jùnliàng
82e089c7dd
Evaluate object and initializer when setting a private method ( #12707 )
...
* fix: evaluate initializer when a private method is set as a field
* make legacy node happy
* add accessor test cases
* fix: evaluate object before RHS
* fix: evaluate object before throwing writeOnlyError
2021-03-01 17:49:59 -05:00
Babel Bot
2c0e8d0008
v7.13.9
2021-03-01 21:33:11 +00:00
Nicolò Ribaudo
c155caf1e8
Load .browserslistrc when using old @babel/core versions ( #12934 )
2021-03-01 20:46:02 +01:00
Huáng Jùnliàng
efdca01409
fix: add tokens when tokens: true is passed to parseExpression ( #12939 )
2021-03-01 14:09:56 -05:00
Nicolò Ribaudo
9844eeee84
Put back ESM helpers in a folder where we can use .js ( #12919 )
2021-03-01 17:31:12 +01:00
Bogdan Savluk
a653b9c08e
Convert @babel/helper-fixtures to typescript ( #12922 )
2021-03-01 16:44:23 +01:00
Michael サイトー 中村 Bashurov
d05fdbc3c7
Fix invalid print output when empty array is passed to t.tsInterfaceDeclaration ( #12921 )
...
If you pass an empty array as `extends` in `t.tsInterfaceDeclaration` you'll get an invalid code printed
```ts
t.tsInterfaceDeclaration(
t.identifier('x'),
undefined,
[],
t.tsInterfaceBody([])
)
```
You will get
```ts
interface A extends {}
```
Which is an invalid TS, this PR fixes that
2021-03-01 10:43:24 -05:00
Michael サイトー 中村 Bashurov
4c343ac853
Allow nullish extends in interfaceish ( #12920 )
...
* Allow nullish extends in interfaceish
Otherwise code such as
```ts
t.interfaceDeclaration(
t.identifier('id'),
undefined,
undefined,
t.objectTypeAnnotation([])
)
```
Will fail when priting with ` TypeError: unknown: Cannot read property 'length' of null`
Despite nullish values being allowed in `t.interfaceDeclaration` definitions
* Update packages/babel-generator/src/generators/flow.ts
Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>
Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>
2021-03-01 10:42:40 -05:00
Sosuke Suzuki
b62fc3d44f
babel-parser(flow): Set this property to null for FunctionTypeAnnotation without parens ( #12930 )
...
* Add null property to FunctionTypeAnnotation without parens
* Update tests
* Update tests
2021-03-01 09:15:43 -05:00
Babel Bot
e2abc19c4c
v7.13.8
2021-02-26 23:28:19 +00:00
Nicolò Ribaudo
ea6a438315
Enable external-helpers by default in tests ( #12911 )
...
Co-authored-by: Huáng Jùnliàng <jlhwung@gmail.com>
Co-authored-by: Babel Bot <babel-bot@users.noreply.github.com>
2021-02-26 23:33:26 +01:00
Alan Lu - 川古
6a0394634f
Don't inject invalid core-js@2 polyfills ( #12901 )
2021-02-25 21:52:21 +01:00
Nicolò Ribaudo
962d81483e
Skip _extends helper for {…x} with modern targets ( #12899 )
2021-02-25 21:16:56 +01:00
Nicolò Ribaudo
9a1b59f1f9
Do not warn for loose of class features in preset-env ( #12898 )
2021-02-25 21:15:48 +01:00
Nicolò Ribaudo
b17231e1af
[internal] Keep the .cjs extension when compiling source files ( #12820 )
...
* [internal] Keep the .cjs extension when compiling
* yarn
2021-02-25 18:03:05 +01:00
Nicolò Ribaudo
bb558aaf28
Allow require() of runtime helpers in Node.js 13.2-13.6 ( #12893 )
2021-02-25 12:28:50 +01:00
Nicolò Ribaudo
039eb2710d
Update all the @babel/* dependencies ( #12897 )
2021-02-25 02:46:56 +01:00
Bogdan Savluk
0a4dc05806
convert @babel/highlight to typescript ( #12432 )
...
Co-authored-by: Nicolò Ribaudo <nicolo.ribaudo@gmail.com>
2021-02-25 01:38:47 +01:00
Nicolò Ribaudo
6a471decc3
Improve @babel/runtime esm stability ( #12883 )
2021-02-24 20:04:03 +01:00