Commit Graph

997 Commits

Author SHA1 Message Date
강동윤
9445c109f9
fix(es/codegen): Fix codegen of arrow expressions. (#1452)
swc_ecma_codegen:
 - Fix codegen of arrow functions.  (#1451)
2021-03-20 15:30:54 +09:00
강동윤
dcdac2db6f
fix(swc): Fix bugs (#1453)
swc_ecma_transforms_typescript:
  - Add option to use define propert for `strip` pass. (#1472)

node-swc:
  - Fix `keepClassNames`. (Brooooooklyn/swc-node#335)
2021-03-17 15:24:35 +09:00
Devon Govett
9d53a70221
fix(common): Fix column positions in generated sourcemaps (#1470)
Co-authored-by: 강동윤 <kdy1@dudy.kr>
2021-03-16 15:18:12 +09:00
Arend van Beelen jr
a90368372f
chore: Add note about required dev tools (#1467) 2021-03-13 00:08:24 +09:00
Alexander van Ratingen
06cb4b89cb
fix(es/codegen): Fix SX spread props (#1463) 2021-03-11 11:24:31 +09:00
강동윤
97269a37b9
fix(swc): Fix bugs for v1.2.50 (#1444)
swc:
 - Respect `react` config.

swc_ecma_transforms_compat:
 - `export-namespace-from`: Preserve `use strict`. (#1423)

swc_ecma_transforms_module:
 - Inject `use strict` before imports. (#1423)

swc_ecma_transforms_proposal:
 - Emit metadata for literal types. (#1421)
2021-03-03 20:39:02 +09:00
강동윤
bc07215d4d
fix(es/parser): Fix lexing of template literals. (#1450)
swc_ecma_parser:
 - Fix lexing of template literals. (denoland/deno#9620)
 - Ensure that denoland/deno#9650 is not a bug of parser.
2021-03-03 17:46:36 +09:00
강동윤
bbaf619f63
fix(bundler): Fix bugs (#1437)
swc_bundler:
 - [x] Fix wrapped esms. (denoland/deno#9307)
 - [x] Make test secure.
2021-03-02 17:33:03 +09:00
Devon Govett
eec65f25bb
feat(es/transforms): Port @babel/preset-modules (#1439)
swc_ecma_preset_env:
 - Add options to enable bugfix transforms.

swc_ecma_transforms_compat:
 - Add bugfix transform for async arrows in a class.
 - Add bugfix transform for default parameters.
 - Add bugfix transform for templit literal caching.

swc_ecma_transforms_react:
 - Respect `use_spread`.

Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2021-03-02 16:03:22 +09:00
Giorgi Rostomashvili
73b8826a2f
fix(es/parser): Recover from type annotations after = (#1445) 2021-03-02 15:50:13 +09:00
강동윤
a3105428ba
fix(swc): Fix various bugs (#1440)
swc:
 - Use `hygiene_with_config` instead. (#1279)
 - Allow enabling source map with `.swcrc`. (#1309)

swc_ecma_transforms_base:
 - `hygiene`: Add an option to preserve class names. (#1279)

swc_ecma_transforms_compat:
 - `block_scoping`: Allow using `break` in switch cases. (#1415)
2021-03-01 17:19:37 +09:00
Sanath Kumar U
7d62fdf761
chore: Fix link (#1443) 2021-03-01 14:06:28 +09:00
marieell
24dac8605b
chore: Typo (#1442) 2021-03-01 13:44:44 +09:00
강동윤
a4d408dc6e
fix(es/transforms/base): Fix span hygiene of type elements (#1436)
swc_ecma_transforms_base:
 - `ts_resolver`: Fix span hygiene of type elements.
2021-02-28 15:55:20 +09:00
강동윤
c047e0e54d
fix(bundler): Fix bundler (#1427)
swc_bundler:
 - Create variables for export while preparing a module. (denoland/deno#9560)
 - Fix order of statements.
 - Invoke dce multiple time if required. (denoland/deno#9546)

swc_ecma_transforms_optimization:
 - dce: Track modifications correctly.
2021-02-26 18:21:42 +09:00
강동윤
05a90715d1 Bump version 2021-02-24 01:58:14 +09:00
LongYinan
6ece76367b
fix(node-swc): Fix glibc compatibility issue (#1431) 2021-02-24 01:53:36 +09:00
Jakub Koralewski
59bd00d841
fix: Fix tests on windows (#1419)
Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2021-02-23 00:33:11 +09:00
강동윤
f28cd51e22 Bump version 2021-02-22 21:50:39 +09:00
playX
abfff69300
fix(common): Allow using with MIRI (#1426) 2021-02-22 21:50:19 +09:00
강동윤
7f5bfdcc00
fix(bundler): Fix bugs (#1382)
swc_bundler:
 - Improve performance
 - Use `Vec<AHashSet<usize>>` instead of `AHashSet<(usize, usize)>`.
 - Fix statement orderings. (denoland/deno#9464) 
 - Fix wrapped esm mixed with circular imports. (denoland/deno#8224)
 - Store content of wrapped esm at top level. (denoland/deno#8224)
2021-02-22 17:27:40 +09:00
David Sherret
adcca03cfa
fix(es/ast): Remove TsTypeCastExpr it's not used (#1420) 2021-02-22 17:05:51 +09:00
LongYinan
9d896c746e
feat(node-swc): Reduce binary size (#1418) 2021-02-20 17:07:58 +09:00
Yehuda Katz
db85d123b7
Fix a number of typos (#1412)
Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2021-02-20 15:18:09 +09:00
강동윤
eecdca4e86
fix(es/transforms/base): Fix resolver (#1414)
swc_ecma_transforms_base:
 - `resolver`: Handle private class methods. (denoland/deno_lint#615)
2021-02-19 19:51:50 +09:00
강동윤
27aad87798
fix(es/transforms/base): Fix hygiene of catch clause (#1413)
swc_ecma_transforms_base:
 - `hygiene`: Apply ops in catch clauses. (#1402)
2021-02-19 16:52:02 +09:00
강동윤
eaeffabf74
fix(es): Improve performance (#1411)
swc_ecma_ast:
 - Add `BindingIdent`.
 - Reduce size of `Ident`.
2021-02-19 15:34:22 +09:00
강동윤
0be20ff0ae
feat(es/transforms/react): New jsx transform (#1408)
swc_ecma_transforms_react:
  - Implement new jsx transform. (#1103, denoland/deno#7993)
2021-02-19 14:32:53 +09:00
강동윤
702e20ef56 Update issue templates 2021-02-17 21:27:55 +09:00
강동윤
8fb0b4c303
fix(es/transforms/react): Use VisitMut instead of Fold (#1409)
swc_ecma_transforms_base:
 - Implement `MapWithMut` for more types.

swc_ecma_transforms_react:
 - Migrate to `VisitMut`.
2021-02-17 14:40:03 +09:00
강동윤
5ad57b02f2
fix(es/parser): Fix bugs (#1405)
swc_ecma_parser:
 - Parse generics in class methods with special name properly.
2021-02-17 01:47:00 +09:00
Ivan Tham
a53186c842
fix(swc): Reduce allocation (#1401) 2021-02-15 23:01:37 +09:00
강동윤
fc2a8cb073
fix(es): Fix docs.rs (#1399) 2021-02-15 02:45:50 +09:00
강동윤
9dabf00200
fix(es): Fix bugs (#1395)
swc_ecma_codegen:
 - Implement `emit_ts_type_assertion`.
 - Implement `emit_ts_type_cast_expr`. 
 - Implement `emit_ts_ns_export_decl`.
 - Implement `emit_ts_signature_decl`.

swc_ecma_parser:
 - Ensure that we report an error for invalid input. (#1391)

swc_ecma_transforms_base:
 - fixer: Handle `await (await foo)()`. (#1397)
2021-02-14 22:18:05 +09:00
Jovi De Croock
f5a90ae985
fix(node-swc): Handle empty object patterns. (#1393)
Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2021-02-14 19:57:15 +09:00
David Sherret
313f51fab1
feat(es/parser): Allow to look at the kind of an error (#1396)
swc_ecma_parser:
 - Add a method to look at the kind of an error without destructuring it.

Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2021-02-14 16:49:28 +09:00
Jovi De Croock
a0898e8ce3
fix(node-swc): Don't remove plugin from options (#1390) 2021-02-13 19:34:35 +09:00
Bartek Iwańczuk
8ef78a9e08
feat: add import assertion to dep analyzer (#1387)
Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2021-02-10 21:49:44 +09:00
강동윤
bf445a75c4
fix(swc): Fix bugs (#1372)
swc_ecma_ast:
 - Support import assertions for exports.

swc_ecma_parser:
 - Support import assertions for exports.

swc_ecma_transform_typescript:
 - Strip `declare globals` correctly. (#1383)

spack:
 - Re-enable multi-entry tests.
2021-02-10 17:25:28 +09:00
LongYinan
79e991bcc3
chore(node-swc): Use latest napi versions (#1386) 2021-02-10 15:47:01 +09:00
강동윤
686c98116d
fix(es): Fix for the type checker (#1381)
swc_ecma_codegen:
 - Fix codegen of `TsCallSignatureDecl`.

swc_ecma_transforms_base:
 - Handle `TsCallSignatureDecl`.
2021-02-08 01:39:05 +09:00
LuisPa
7a93594229
docs: Fixed documentation link URL in README.md (#1375)
Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2021-02-04 12:12:54 +09:00
Yehuda Katz
98ae16761d
fix(node): Add es2020 to JscTarget in types.ts (#1376) 2021-02-04 12:12:19 +09:00
Michael Nicholls
bd119e6634
feat(es/preset-env): Custom config path (#1374)
swc_ecma_preset_env:
 - Support custom path.

Co-authored-by: 강동윤 <kdy1@dudy.kr>
2021-02-03 13:27:11 +09:00
강동윤
bfde9a1f6e
fix(bundler): Fix bugs (#1373)
swc_bundler:
- Handle export default-ed functions correctly.
2021-02-01 12:31:03 +09:00
강동윤
0d130f8103
fix(bundler): Prevent hanging (#1369)
swc_bundler:
 - Prevent infinite loop.
2021-01-30 13:35:07 +09:00
강동윤
af25a88902
fix(swc): Fix bugs for v1.2.47 (#1368)
swc_ecma_parser:
 - Fix generic parsing issue in jsx context. (#1299)

swc_ecma_transforms_module:
 - Allow importing a module multiple time. (#1232)
 - Handle imports in the constructor of an exported class decl. (#1213)

swc:
 - Respect `sourceMappingURL`. (#1236)
 - Resolve `sourceMappingURL` relative from file. (#1255)
 - Respect `isModule: false` (#1258)

spack:
 - Support loading json files. (#1225)
2021-01-29 22:19:04 +09:00
LongYinan
ca417e9d59
feat(node-swc): Support windows ia32 arch (#1367) 2021-01-29 15:09:44 +09:00
David Sherret
4155822283
Fix span of arrow expression with type params (#1365)
swc_ecma_parser:
 - Fix span of arrow expression with type params.

Co-authored-by: 강동윤 <kdy1997.dev@gmail.com>
2021-01-28 20:55:43 +09:00
강동윤
767f21e9dd
fix(bundler): Fix pass ordering (#1363)
swc_bundler:
 - Invoke iife handler before fixer.
2021-01-27 20:20:39 +09:00