swc/CHANGELOG.md
2022-05-24 13:32:27 +00:00

331 KiB

Changelog

[unreleased]

Bug Fixes

  • (css/parser) Allow var() call in color functions (#4713) (07d31aa)

  • (es/compat) Fix span of instanceof (#4757) (8720f9a)

  • (es/compat) Handle nested for loops with break/continue (#4777) (4f00914)

  • (es/compat) Handle nested break/continue in block_scoping (#4778) (db1698e)

  • (es/compat) Escape keywords in class method names (#4775) (a3e4c20)

  • (es/fixer) Preserve the paren in a spread element (#4771) (65b7c4b)

  • (es/loader) Fix jsc.paths on windows (#4739) (417b218)

  • (es/loader) Fix hang related to jsc.paths (#4742) (777ea37)

  • (es/minifier) Consider parameters while detecting pure calls (#4748) (e4dee1e)

  • (es/modules) Adjust absolute path while rewriting imports (#4776) (75bb858)

  • (es/modules/cjs) FIx detection of exported names (#4737) (d9bb59a)

  • (es/resolver) Handle var after catch with the same name (#4772) (e2da3dd)

  • (es/resolver) Fix more edge cases related to catch and var (#4773) (f28d9c1)

  • (es/typescript) Mark namespaces as concrete (#4736) (41d4437)

  • (es/typescript) Preserve referenced imports for namespace (#4759) (065b2a5)

  • (html/codegen) Emit textarea and pre in foreign context (#4766) (8662665)

  • (html/parser) Fix error reporting in the foreign context (#4725) (4df0637)

  • (html/parser) Fix parsing of closing tag in foreign contents (#4721) (1c4d50f)

Features

  • (es/helpers) Import only used helpers (#4767) (b8d2fb8)

  • (es/minifier) Implement pure_funcs (#4710) (9e42382)

  • (es/minifier) Handle prefix update expressions with sequential inliner (#4741) (a51816a)

  • (es/minifier) Implement more rules (#4763) (20b724d)

  • (es/modules/amd) Support local-scoped amd requires (#4727) (886585b)

  • (html/codegen) Omit end tags (#4770) (07c197f)

  • (html/parser) Improve error reporting for misplaced non-space characters inside a table (#4723) (e9b2ebf)

  • (html/parser) Improve error reporting (#4728) (c346d30)

  • (html/parser) Improve error reporting (#4740) (51f4cea)

  • (html/parser) Improve public api (#4762) (c07780f)

  • (plugin) Implement more SourceMap apis (#4769) (3298cb7)

Miscellaneous Tasks

  • (ci) Fix CI (#4747) (0f85f7b)

  • (es/minifier) Add #[doc(hidden)] (#4751) (22bf5f0)

Performance

  • (common) Add more methods to Spanned (#4749) (98df645)

Refactor

  • (es/minifier) Make rust-analyzer faster (#4744) (47e6cc5)

  • (es/minifier) Make rust-analyzer fast, really (#4746) (49b3c27)

  • (es/parser) Remove duplicate (#4750) (b7a195a)

Testing

  • (html/parser) Enable error reporting tests (#4764) (984d69e)

[1.2.189] - 2022-05-21

Bug Fixes

  • (es/codegen) Fix numeric literals (#4733) (ea46eb4)

  • (es/config) Respect .swcrc (#4735) (9966e98)

  • (html/parser) Fix error reporting related to image (#4720) (4cee4ac)

[1.2.188] - 2022-05-21

Bug Fixes

  • (es/codegen) Exclude synthesized files from sourcemap (#4714) (03dd9de)

  • (es/codegen) Fix numeric literals (#4731) (f1baff4)

  • (es/minifier) Consider more side effects while inlining (#4715) (1358f45)

  • (html/parser) Fix handling of unclosed td/th (#4719) (2c2e6bb)

Features

  • (es/minifier) Implement more skipping rules for sequences (#4716) (dc67911)

  • (html/parser) Report an error for a legacy doctype (#4717) (5d0e8fb)

[1.2.187] - 2022-05-20

Bug Fixes

  • (common) Don't use reserved byte position (#4690) (606f7c9)

  • (es/ast) Fix EqIgnoreSpan of Ident (#4689) (07356a5)

  • (es/codegen) Don't add a newline after an arrow body (#4711) (72fbf69)

  • (es/compat) Fix break in for await loop (#4705) (100c0b5)

  • (es/config) Auto-detect tsx (#4696) (ad309f4)

  • (es/config) Add jsc.output.charset (#4708) (bf5ba28)

  • (es/minifier) Don't hoist functions with dead_code (#4695) (183e884)

  • (es/minifier) Don't create keys with negative number (#4698) (809a626)

  • (es/minifier) Fix analysis of assignment patterns (#4712) (73dfa95)

  • (es/modules) Fix reassignment of exported vars (#4688) (7ce572b)

  • (es/react) Fix span of error messages (#4704) (5f45a3d)

  • (html/parser) Fix span of attributes (#4681) (637ef7f)

  • (html/parser) Fix bugs (#4707) (0b39e1b)

Features

  • (es/minifier) Improve if_return (#4694) (274648e)

  • (html/minifier) Compress characters in head (#4682) (cac8cee)

Performance

  • (es/minifier) Make minifier more parallel (#4699) (9a27b5f)

Testing

  • (es) Add a test for a fixed issue (#4693) (b93af7b)

  • (es/minifier) Categorize more tests (#4709) (6f565fb)

[1.2.186] - 2022-05-17

Bug Fixes

  • (es/minifier) Consider fallthrough while merging swtich cases (#4672) (3bb4b74)

Features

  • (dbg-swc) Make reducer parallel (#4676) (ba6688a)

  • (es) Add check for BytePos::DUMMY (#4675) (da49f81)

  • (es/minifier) Enable computed_props by default (#4678) (04d66db)

  • (es/minifier) Enable conditionals by default (#4687) (c01476d)

  • (html/minifier) Compress more json content (#4684) (3aac28e)

Miscellaneous Tasks

  • general: Add stale workflow (890a5ae)

Performance

  • (common) Improve performance of StringInput (#4680) (fe1e62a)

  • (html) Setup benchmarks (#4685) (b56f3b7)

Testing

  • (es/minifier) Add size tests using dbg-swc (#4664) (36ff4f7)

  • (html/parser) Add tests for broken html/svg (#4683) (1d9ee0a)

[1.2.185] - 2022-05-15

Bug Fixes

  • (es/modules) Fix handling of import.meta.url (#4670) (49c40af)

Features

  • (dbg-swc) Add a command to diff semantics (#4671) (e3cda26)

  • (es/minifier) Improve ignore_return_value (#4673) (e57123e)

Build

  • (repo) Downgrade rustc (#4674) (50db276)

[1.2.184] - 2022-05-15

Bug Fixes

  • (es/minifier) Don't inline a function if we need referential equality (#4665) (96cec97)

  • (html/parser) Fix error reporting (#4644) (1f945b9)

Documentation

  • (es/codegen) Document ascii_only (#4669) (bfb6be7)

Features

  • (dbg-swc) Add command to compare minifier (#4653) (af1d195)

  • (dbg-swc) Add auto-reducer for the minifier (#4654) (c8818b0)

  • (es) Add an option to omit columns from sourcemaps (#4646) (b6f904b)

  • (es/codegen) Implement ascii-only (#4660) (eb8508f)

  • (es/lints) Implement no-sparse-arrays rule (#4652) (9b226a7)

  • (es/minifier) Improve minifier (#4655) (053f42b)

  • (es/minifier) Implement directives (#4668) (8a40b58)

  • (html) Support iframe_srcdoc (#4658) (69ca949)

  • (html/parser) Improve error reporting (#4663) (a8467c6)

Performance

  • (es/parser) Optimize for cpu code cache (#4666) (11726cc)

Refactor

  • (es/react) Use proper ident scope for react refresh (#4649) (1150e84)

Build

  • (repo) Update rustc (#4667) (98e4845)

[1.2.183] - 2022-05-13

Bug Fixes

  • (css/parser) Remove a wrong assertion (#4641) (84e4ca6)

  • (es/minifier) Don't create direct eval (#4634) (56a227a)

  • (es/minifier) Fix optimization of spread (#4639) (9c190f0)

  • (es/modules) Fix jsc.paths (#4620) (20692cd)

  • (es/resolver) Ensure that a parameter type is resolved to parent (#4645) (2745cb7)

  • (html) Fix parsing of template (#4647) (af9c8c6)

  • (html/codegen) Fix codegen (#4629) (fa4a60a)

  • (html/parser) Fix newlines (#4633) (a19db29)

Features

  • (common) Reserve BytePos(0) for dummy spans (#4616) (67942d5)

  • (debug) Inline dbg-swc (#4651) (b393773)

  • (es/lints) Implement no-compare-neg-zero rule (#4643) (f45dd72)

  • (html/minifier) Improve minification of attributes (#4625) (5679b69)

  • (html/minifier) Compress application/ld+json (#4628) (c41aca6)

  • (html/parser) Add a method to get error message (#4623) (cac4f6e)

Refactor

  • (html/parser) Remove unused code (#4613) (a378e1e)

  • (html/parser) Improve public API (#4626) (b8fa3bc)

  • (html/parser) Improve parser a bit (#4627) (5f899a0)

Testing

  • (es) Add a test for merging configurations (#4617) (53ff81c)

  • (es/minifier) Execute more tests (#4636) (79f87e0)

  • (html/parser) Add dom visualizer for regular tests (#4622) (4e577d7)

[1.2.182] - 2022-05-11

Bug Fixes

  • (es/config) Merge jsc.transform correctly (#4615) (3b2b8c4)

  • (es/fixer) Handle new yield (#4598) (d611d54)

  • (es/minifier) Fix switches (#4595) (2ab7594)

  • (es/minifier) Fix with and NaN (#4596) (097ff1d)

  • (es/minifier) Fix switch with a unknown case (#4597) (8944a3b)

  • (es/minifier) Preserve more this (#4599) (859dc44)

  • (es/utils) Fix wrong apis (#4604) (6a97c7b)

  • (html/parser) Fix bugs (#4592) (7166dbf)

Features

  • (css/parser) Add a method to get error message (#4588) (04dd3dd)

  • (es/ast) Improve Id APIs (#4614) (2c861bd)

  • (es/hygiene) Drop syntax context (#4594) (6ac4a23)

  • (es/lints) Implement prefer-const rule without options (#4584) (e65bf3d)

Refactor

  • (html) Refactor parser and codegen (#4611) (7c6627f)

Testing

  • (es/minifier) Postpone tests which can be verified by execution tests (#4600) (6918e3a)

[1.2.181] - 2022-05-09

Bug Fixes

  • (es) Use unresolved_mark (#4573) (0868409)

  • (es/minifier) Improve sequential inliner (#4570) (af368ee)

  • (es/minifier) Preserve more identifiers if eval or with exists (#4580) (e43689b)

  • (es/minifier) Don't create an invalid labeled statement (#4581) (7e80c10)

  • (es/minifier) Unwrap blocks more carefully (#4586) (8db3442)

  • (es/minifier) Consider more aliases in sequences pass (#4583) (3521ce0)

  • (es/minifier) Fix handling of NaN (#4593) (dd09cdf)

  • (es/resolver) Fix handling of a complex try catch (#4574) (9e79f9c)

  • (es/resolver) Fix more try catch issues (#4582) (56c3010)

  • (html/parser) Add recovery for attributes on html and body (#4566) (c7d20e4)

  • (node) Use jemallocator on linux (#4591) (af91094)

Features

  • (config) Make all configuration overridable (#4575) (7fc9bbc)

  • (es/ast) Add methods for parens (#4576) (55d0ee6)

  • (html/parser) Parse document fragment (#4579) (a34dea1)

Miscellaneous Tasks

  • (ci) Improve CI scripts (#4572) (f23c943)

Refactor

  • (html/parser) Resolve TODO (#4577) (4cc247f)

Testing

  • (es/minifier) Fix test system (#4571) (bf5ee01)

  • (html/parser) Add tests (#4565) (adbce64)

  • (html/parser) Improve script on/off tests (#4564) (4838267)

[1.2.179] - 2022-05-08

Bug Fixes

  • (es/minifier) Distinguish raw and cooked while joining template literals (#4559) (f9b6016)

  • (es/minifier) Fix handling of template literals (#4563) (920d9a7)

  • (html/parser) Fix for noah's ark clause (#4558) (7ef6372)

  • (html/parser) Fix adoption agency algorithm (#4552) (d6e4885)

Documentation

  • (es/resolver) Add docs for top-level mark (#4560) (13cc228)

Features

  • (es/minifier) Drop vars using sequential inliner (#4547) (c5b4ef4)

  • (es/minifier) Remove duplicate control flow in nested blocks (#4569) (b3b6fd4)

Refactor

  • (plugin) Align deps (#4568) (846a319)

[1.2.178] - 2022-05-07

Bug Fixes

  • (es/compat) Memorize computed props in logical assignment (#4525) (2e74787)

  • (es/minifier) Respect keepClassNames for class expressions (#4536) (3d5d234)

  • (es/minifier) Skip getter/setter when collapsing vars (#4557) (5d3a01a)

  • (es/modules) Preserve extensions (#4524) (f3b262e)

  • (es/parser) Revert #4067 (#4540) (2831059)

  • (es/parser) Revert #4287 (#4542) (e2fde1a)

  • (html/lexer) Fix lexing of numeric characters (#4544) (6980381)

  • (html/parser) Fix a bug related to parsing foreign elements (#4527) (2f6f8fa)

  • (html/parser) Fix parsing of cdata in foreign context (#4531) (5dc9376)

  • (html/parser) Fix a bug with optional li (#4526) (6310eab)

  • (html/parser) Fix parsing of comments in textarea (#4530) (79090e1)

  • (html/parser) Fix parsing of nobr (#4535) (e6042a5)

  • (html/parser) Fix parsing of cdata (#4537) (07cf28a)

  • (html/parser) Fix parsing of newline in textarea (#4543) (dd40e7b)

  • (html/parser) Fix support for document mode (#4539) (e11ee88)

Features

  • (plugin) Make plugin source map api use SourceMapper (#4541) (10f903d)

Miscellaneous Tasks

  • (repo) Configure prettier (#4523) (a6d404a)

Refactor

  • (html/parser) Cleanup (#4545) (446172f)

Testing

  • (es/minifier) Categorize more tests (#4538) (3d3e3bb)

  • (es/minifier) Ignore difference of parens (#4546) (b0efd00)

  • (html/parser) Add integration tests from html5lib-test (#4517) (a4a815b)

Build

  • (plugin) Update swc_plugin_proxy (#4551) (b5a2033)

[1.2.177] - 2022-05-04

Bug Fixes

  • (html/parser) Fix a bug of unwrapping element without parent (#4505) (597c0c6)

  • (node) Fix tls allocation issue (#4514) (3d5c0fa)

Features

  • (es/parser) Reject accessors named constructor (#4520) (0e0ded1)

  • (plugin) Expose Pos (#4516) (c0432e4)

Miscellaneous Tasks

  • (repo) Fix lints (#4519) (33f58fa)

Testing

  • (html/parser) Add tests (#4507) (202a6e4)

[1.2.176] - 2022-05-04

Bug Fixes

  • (es/compat) Revert a wrong patch about private properties (97e0e27)

  • (es/compat) Fix the position of inserted statements in class_properties (#4511) (9e45882)

[1.2.175] - 2022-05-03

Bug Fixes

  • (css/prefixer) Add prefix for print-color-adjust (#4503) (90ac93a)

  • (es/bugfixes) Fix handling of syntax context (#4490) (a444726)

  • (es/compat) Support updating a private field with bigint value (#4136) (1e1d081)

  • (es/compat) Visit default export in static_block (#4500) (c4b156c)

  • (es/decorators) Make legacy decorator identical to tsc (#4496) (f30ffdf)

  • (html/parser) Fix adoption agency algorithm (#4487) (00358e1)

  • (html/parser) Fix bugs (#4502) (fca84eb)

  • (html/parser) Fix parsing of select (#4504) (b8588c4)

  • (html/parser) Fix parsing of a table with a table (#4506) (efe87bc)

  • (node/types) Add types for jsc.minify.format (#4492) (3ed1538)

Features

  • (es/compat) Verify private property access (#4465) (de53a6f)

  • (es/lints) Implement no-var (#4485) (17f237d)

  • (es/parser) Reject private field called #constructor (#4491) (857e798)

  • (es/preset-env) Update data (#4497) (5c5337d)

Refactor

  • (es/minifier) Cleanup (#4489) (50b2049)

Testing

  • (es/decorators) Migrate some tests to file-based fixture tests (#4510) (8629e0c)

[1.2.174] - 2022-04-30

Bug Fixes

  • (es/helpers) Update _interopRequireWildcard (#4479) (7d40208)

  • (es/minifier) Disable some passes for hoist_props (#4468) (effc85d)

  • (es/minifier) Fix skipping logic of sequential inliner (#4469) (233c4d5)

  • (html) Fix bugs of parser and codegen (#4461) (8bdfcd9)

  • (html/parser) Fix bugs (#4459) (2098228)

Features

  • (es/lints) Implement no-throw-literal (#4477) (3a8cade)

  • (es/minifier) Drop more returns (#4471) (2739546)

  • (es/minifier) Consider cost of functions for inlining (#4470) (7a584d7)

  • (es/minifier) Drop pure new calls (#4478) (918c9c8)

  • (es/minifier) Add pristine_globals (#4480) (09ba3c0)

  • (html/minifier) Remove javascript: prefix (#4460) (a1877e7)

  • (html/minifier) Remove duplicate attributes (#4474) (750d655)

Miscellaneous Tasks

  • (es/minifier) Update debugging utils (#4467) (c45b0df)

[1.2.173] - 2022-04-28

Bug Fixes

  • (es) Remove wrong debug assertion (#4445) (962cf4a)

  • (es/async-generator) Fix yield* in async generators (#4452) (0bc0bae)

  • (es/parser) Throw syntax error for missing function expr body (#4462) (393cfa8)

  • (es/preset-env) Do not import new features when using old core-js (#4458) (4262874)

  • (html/parser) Fix a bug with nested tags (#4438) (8c4dc4c)

  • (html/parser) Parse table including broken one (#4451) (6e60813)

  • (html/parser) Fix fosting logic for text nodes (#4457) (65a158a)

Features

  • (es/parser) Reject indirect opt chain in assignment (#4447) (df7b3f6)

  • (html/minifier) Compress whitespaces (#4463) (0ae4350)

Miscellaneous Tasks

  • (es/minifier) Don't run tests with infinite loops (#4448) (ec7dfb9)

Testing

  • (html/codegen) Improve fixture testing (#4450) (f30e771)

[1.2.172] - 2022-04-26

Bug Fixes

  • (es/ast) Fix tag of BigInt (#4440) (2813eaa)

  • (es/minifier) Remove the last break in the last BlockStmt (#4413) (83244ad)

  • (es/minifier) Don't drop arguments to an IIFE without body (#4419) (aa19b65)

  • (es/minifier) Preserve more side effects (#4420) (8ab12fd)

  • (es/minifier) Fix analysis of update expressions (#4428) (9733917)

  • (es/minifier) Remove wrong logic for optimizing deletes (#4429) (8118569)

  • (es/parser) Fix top-level await with binary expr (#4426) (465cc2f)

  • (html/lexer) Fix lexing of html entity (#4423) (9b26dbd)

  • (html/parser) Parse foreign attributes (#4400) (cf3be64)

  • (html/parser) Fix parsing of foreign elements (#4422) (4ccbdf2)

  • (html/parser) Fix span (#4437) (3293060)

  • (html/parsing) Fix parsing of formatting elements (#4442) (8f2a3ea)

Features

  • (es/optimization) Accept top level mark from simplifiers (#4434) (8048597)

  • (es/parser) Reject invalid regex flags (#4404) (c96e322)

  • (es/parser) Reject invalid new.target (#4406) (da02c9d)

  • (es/parser) Reject 'use strict' with non-simple params list in TS (#4416) (6dc64c9)

  • (es/resolver) Use different syntax context for unresolved refs (#4436) (53610fd)

  • (html) Prepare processing system (#4358) (7332dce)

  • (html/codegen) Print unquoted value when it is possible (#4402) (c15dc4f)

  • (html/minifier) Initialize crate (#4403) (63a6280)

  • (html/minifier) Remove script type attribute (#4407) (fec0f2e)

  • (html/minifier) Compress type for style and link tags (#4424) (25a87f0)

  • (html/minifier) Compress doctype (#4425) (6fc70f3)

  • (html/minifier) Compress default values of attributes (#4427) (4c699f2)

  • (node/css) Add css bindings crate (#4346) (6a19ff1)

  • (preset-env/base) Update "browserslist-rs" (#4435) (1c2af93)

Miscellaneous Tasks

  • (ci) Improve bot script (#4430) (c216a03)

  • (ci) Use yarn instead of npm (#4432) (b3fb0e9)

  • (es/minifier) Add a script to instrument real-world inputs (#4399) (efdf93d)

  • (plugin) Add a benchmark (#4397) (60efb7e)

  • (repo) Make git commit faster (#4421) (65e00aa)

Performance

  • (es/minifier) Add some fast-path to the MultiReplacer (#4408) (4c9e5c0)

Testing

  • (es) Add tests for .swcrc (#4398) (5134b4f)

  • (es/minifier) Split tests into improvement and stabilization (#4409) (ab88637)

  • (es/minifier) Use _ instead of - for terser tests (#4411) (4e11303)

  • (es/minifier) Execute terser tests if possible (#4418) (f787f8c)

  • (es/minifier) Categorize tests (#4410) (9b34ecf)

[1.2.171] - 2022-04-22

Bug Fixes

  • (common) Ignore extraneous mapping of 1, 0 => 0, 0 (#4381) (a06c559)

  • (es) Fix CI (#4385) (805238a)

  • (es/codegen) Allow non-ascii character in more places (#4394) (139ac24)

  • (es/minifier) Don't drop labels if required (#4370) (922299a)

  • (es/minifier) Preserve more labels (#4380) (87859e3)

  • (es/minifier) Disable conditionals by default (#4391) (375cc59)

  • (plugin) Align deps to fix build (#4377) (8419b60)

  • (plugin) Align deps for the plugin (#4384) (46e88a3)

Features

  • (es/minifier) Improve handling of switches (#4260) (8cf3ddd)

  • (es/parser) Reject await expr with ** (#4395) (59f63da)

Miscellaneous Tasks

  • general: Fix wasm publish script (234e380)- general: Fix CI (11012d0)- general: Fix CI, really (000e31b)

Testing

  • (es/parser) Add a test for a fixed issue (#4388) (b9cba1a)

[1.2.170] - 2022-04-20

Performance

  • (es/minifier) Fix default of TerserCompressorOptions (#4378) (203dde9)

Testing

  • (es/minifier) Organize tests (#4375) (4a8b1da)

[1.2.169] - 2022-04-20

Bug Fixes

  • (es/lexer) Fix handling of object properties with the name function (#4374) (3bdf5a8)

  • (es/minifier) Fix default values of toplevel (#4366) (128175c)

  • (es/minifier) Apply name mangler as much as we can (#4365) (a8ed5ba)

  • (es/minifier) Apply name mangler even more (#4368) (4b1590e)

  • (es/modules/cjs) Fix order of statements (#4361) (5c1ce0b)

Features

  • (cli) Support configuring output file extension (#4343) (c4f01c6)

  • (es/minifier) Implement more evaluation rules (#4356) (e13b862)

  • (es/minifier) Improve evaluation of template literals (#4359) (2e095fa)

  • (es/minifier) Implement all template literal evaluation rules (#4360) (e60ae2a)

  • (plugin) Support lookup_char_pos of SourceMap (#4364) (f06c862)

Miscellaneous Tasks

  • (es) Rename benchmarks (#4355) (8309440)

  • (es/minifier) Setup correct benchmark (#4372) (5d179bf)

  • (node/types) Add unsafe to compress options (#4362) (b63cd53)- general: Remove an incorrect link in CONTRIBUTING.md (#4363) (c661d5f)

Performance

  • (es/minifier) Make base54 use stack-allocated vector (#4371) (6300b9c)

  • (es/minifier) Change default value of passes to 3 (#4373) (a8eb00c)

Testing

  • (es/parser) Add a test for a fixed issue (#4357) (bf76175)

[1.2.168] - 2022-04-17

Bug Fixes

  • (es/codegen) Emit decorators before export (#4349) (4953ce4)

  • (es/minifier) Preserve vars in dead branches (#4345) (5a5e41a)

Features

  • (es/minifier) const => let (#3654) (b3b95ac)

Miscellaneous Tasks

  • (es/minifier) Organize scripts (#4347) (14c74f5)

  • (es/minifier) Improve scripts (#4339) (2563c7f)

  • (repo) Make git commit faster (#4353) (f7df3d8)- general: Fix CI script (a953455)

Performance

  • (es) Disable wrong parallelization (#4354) (da6fa60)

  • (es/minifier) Split frequently used functions (#4352) (42e15ae)

[1.2.167] - 2022-04-17

Bug Fixes

  • (es/parser) Reject optional constructor call (#4340) (31b3336)

Miscellaneous Tasks

  • (ci) Fix wasm publish script (1900d35)

Performance

  • (es/minifier) Make name mangler faster (#4342) (66ff7b8)

[1.2.166] - 2022-04-15

Bug Fixes

  • (css/parser) Parse legacy calcs (#4320) (81370d1)

  • (css/prefixer) Don't prefix if it's already prefixed (#4307) (690ce26)

  • (css/prefixer) Handle at-rules and don't generate unnecessary prefixes (#4318) (ac4f14a)

  • (css/prefixer) Fix more bugs (#4330) (405e5ed)

  • (es/codegen) Fix overflow of numeric literals (#4321) (0245e26)

  • (es/codegen) Fix codegen of arrow expressions (#4306) (4c99730)

  • (es/compat) Fix renaming bug of block_scoping (#4310) (6c9882e)

  • (es/lints) Check parameters in the duplicate binding rule (#4288) (e4a565c)

  • (es/loader) Fix traversal of node modules resolver (#4327) (780de70)

  • (es/minifier) Fix inlining of uninitialized variables (#4292) (b990b19)

  • (es/minifier) Respect dead_code (#4328) (8886a4b)

  • (es/minifier) Inline before cloning (#4338) (4110fcb)

  • (es/parser) Enable static blocks by default (#4334) (7599fe7)

  • (es/parser) Make parsing of TS InstantiationExpr more permissive (#4332) (ea466af)

  • (node-swc/types) Add isTypeOnly to types (#4303) (1a48732)

Features

  • (css/minifier) Compress colors (#4308) (65b18ee)

  • (es) Support typeof with private fields (#4302) (d0de5a6)

  • (es/minifier) Enable conditionals by default (#4301) (7e8f613)

  • (es/minifier) Enable dead_code by default (#4309) (74a5087)

  • (es/minifier) Improve sequential inliner (#4335) (f92242d)

  • (es/parser) Support extends clause to infer type (#4326) (1c3d1af)

Miscellaneous Tasks

  • (*) Typo + fomatting (#4304) (37a8c90)

  • (ci) Fix CI (#4299) (adea17d)

  • (es/minifier) Update terser test references (#4297) (df0d572)

  • (es/minifier) Add full benchmark for .minify() (#4341) (ba5f743)

Refactor

  • (bindings) Rename crates (#4337) (83a8f48)

  • (es/minifier) Clean up logging (#4322) (2002554)

  • (es/parser) Simplify logic (#4329) (37aec5b)

[1.2.165] - 2022-04-09

Bug Fixes

  • (css/prefixer) FIx a bug related to writing-mode (#4278) (7f38e06)

  • (es/minifier) Fix handling of eval (#4273) (c961371)

  • (es/module) Support top-level await in dynamic imports (#4277) (720244f)

  • (es/optimization) Don't create invalid sequence expressions (#4285) (4868c73)

Features

  • (html) Add raw fields (#4281) (ee108af)

  • (plugin) Implement Copy and Clone for the comment proxy (#4280) (3c4e520)

  • (plugin) Make more types serializable (#4289) (281db2c)

  • (plugin/runner) Allow fs access from wasi plugin (#4279) (fc3a2d0)

Miscellaneous Tasks

  • (plugin) Align version of swc_common to include dummy comment api (#4270) (fad652f)

Refactor

  • (es/minifier) Merge code for multi-replacer (#4269) (434dcf4)

  • (plugin/api) Expand the proxy crate (#4290) (cf7ca50)

[1.2.164] - 2022-04-07

Bug Fixes

  • (es/codegen) Commit ; before a template literal (#4252) (8cd903b)

  • (es/codegen) Handle comments on the argument of throw (#4254) (ccd3188)

  • (es/minifier) Remap variables on IIFE evaluation (#4230) (55b98fc)

  • (es/minifier) Handle empty RegExp (#4235) (6a51d04)

  • (es/minifier) Fix infinite loops (#4250) (350a195)

  • (es/optimizer/simplifier) Collect idents in init first (#4239) (b1645f6)

  • (es/parser) Support error reporting for TS1274 (#4232) (6d380ea)

  • (es/parser) Adjust context in a function block (#4264) (b89937c)

  • (html/parser) Support cdata (#4259) (3f6037b)

  • (html/parser) Fix bugs (#4265) (105a0cc)

Features

  • (css/parser) Improve error recovery for unknown at-rules (#4257) (8b6647c)

  • (es) Support jsonc for .swcrc (#4236) (8008b79)

  • (es/ast) Add raw to Num (#4245) (f39d3ac)

  • (es/minifier) Improve sequential inlining (#4231) (fe358ad)

  • (es/minifier) Improve inliner and evaluator (#4216) (4701da5)

  • (es/minifier) Exclude local bindings from aliases (#4261) (ab1f440)

  • (es/minifier) Implement more rules for hoist_props (#4262) (1f5cac4)

  • (es/parser) Report more errors (#4244) (674275c)

  • (html) Initialize (#4240) (3e7872c)

  • (html) Support boolean attributes (#4258) (8640c8b)

  • (plugin) Implement proxy for dummy_with_cmt (#4268) (b15e984)

  • (plugin/api) Expose swc_ecma_utils (#4256) (7bc04a6)

Miscellaneous Tasks

  • (bench) Migrate to criterion (#4237) (06d0891)

  • (build) Dedup swc_common (#4247) (4093814)

  • (ci) Fix benchmark action (#4242) (1f466e1)

  • (es/preset-env) Typo (#4243) (06020bb)

Refactor

  • (plugin) Consolidate exported namespaces (#4263) (8706c17)

Testing

  • (es) Organize tests (#4251) (c32f42b)

  • (es/parser) Add a test for a fixed issue (#4255) (1f0039f)

[1.2.163] - 2022-04-03

Bug Fixes

  • (cli) Update plugin template (#4222) (69cb512)

  • (css/prefixer) Fix flex box (#4212) (75b0ed5)

  • (es/preset-env) Change order of passes (7eea95b)

Features

  • (css/ast) Derive more traits (#4220) (def2826)

  • (es/ast) Add raw to BigInt (#4218) (e91f271)

  • (es/compat) Support more regex expressions (#4205) (b793aa0)

  • (plugin) Implement plugin api for comments (#4229) (6ea66cf)

Performance

  • (es/minifier) Add fast-path for sequences pass (#4217) (688f653)

  • (es/parser) Improve performance by using #[cold] (#4215) (1645562)

Refactor

  • (css/ast) Union all at-rules to one at-rule in AST (#4189) (6696a93)

Testing

  • (es) Add a test to ensure that an issue is not a bug of swc (#4227) (bbbaf15)

[1.2.162] - 2022-03-31

Bug Fixes

  • (es/compat) Handle spreads of string literials (#4191) (4f5c5cf)

  • (es/compat) Handle new.target in getter/setter properties (#4194) (3426dda)

  • (es/compat) Fix label handling of block_scoping (#4198) (c946236)

  • (es/compat) Hoist env in function params (#4210) (6a27a0c)

  • (es/minifier) Fix react-ace (#4183) (9a9a4f3)

  • (es/minifier) Fix evaluation of IIFEs (#4207) (1071854)

  • (es/optimization) Support jsx in dce (#4203) (073751f)

  • (es/parser) Fix parsing of an arrow and a conditional expression (#4199) (99a0d34)

  • (node-swc) Initialize custom trace subscriber only once (#4209) (eecda21)

Features

  • (common/preset-env) Dedup arrayvec (#4201) (1ad357c)

  • (es/minifier) Evaluate trivial expressions (#4179) (a6f6799)

  • (es/minifier) Optimize switches more correctly (#4180) (6d3ea17)

  • (es/minifier) Evaluate more iifes (#4200) (11fe5fa)

  • (es/parser) Allow parsing files with missing close braces (#4187) (cffe5ca)

  • (plugin) Implement PoC of comments api (#4206) (536a190)

Miscellaneous Tasks

  • (es/parser) Add span tests back (#4186) (1759567)

Refactor

  • (*) Remove fastmem (#4211) (3b1da22)

  • (cli) Alias plugin build with wasm target (#4181) (8ca4e67)

[1.2.161] - 2022-03-28

Bug Fixes

  • (cli) Fix executable permission (#4154) (e1d1d82)

  • (es) Make ErrorConfig.filename default to true (#4150) (7a1dcb1)

  • (es) Consume surrogate pairs (#4115) (fcf67c4)

  • (es/codegen) Fix codegen of template literals (#4124) (f5a5217)

  • (es/codegen) Emit sourcemap of key-value properties correctly (#4166) (ea0de90)

  • (es/lints) Ignore type-only imports while checking duplicates (#4163) (fce554c)

  • (es/parser) Allow arrows without parenthesized param in typescript (#4138) (ab4ea9f)

  • (es/parser) Fix logic for consuming ts modifiers (#4137) (f5ce79a)

Features

  • (cli) Implements some compile flags (#4125) (a6f39d3)

  • (css/minifier) Compress more properties (#4130) (93866d0)

  • (css/minifier) Remove @charset at-rule if possible (#4135) (6b6664a)

  • (css/minifier) Compress more properties (#4155) (364ebd9)

  • (css/prefixer) Prefix more properties (#4153) (46c35da)

  • (es/codegen) Compress \t in string literals more (#4131) (48f3dc8)

  • (es/lints) Use Str.raw instead of source map (#4139) (d8a988e)

  • (es/lints) Improve error messages (#4142) (0f92eda)

  • (es/lints) Implement no-param-reassign rule (#4134) (47712de)

  • (es/lints) Remove source map accesses (#4147) (7a06c5b)

  • (es/lints) Implement symbol-description rule (#4161) (10851ec)

  • (es/lints) Implement no-obj-calls rule (#4168) (a88d56e)

  • (es/minifier) Implement some unsafe evaluation rules (#4133) (1d3763d)

  • (es/minifier) Implement more rules for optimizing for-if-break (#4140) (ee5c48c)

  • (es/minifier) Implement rules for optimizing loops (#4157) (b37dafb)

  • (es/minifier) Implement more rules for dropping unused assignemnts (#4171) (6f25e57)

  • (es/parser) Report more errors for invalid patterns (#4145) (cd7112b)

  • (es/plugin) Make quote optional (#4160) (5de3141)

  • (es/typescript) Support optional variance annotations (#4008) (bf1924d)

  • (plugin/runner) Implement initial loading for wasm32 (#4151) (161353c)

  • (wasm/plugin) Implement initial plugin interface for wasm runtimes (#4123) (50f7f46)

Miscellaneous Tasks

  • (deps) Update string-cache (#4169) (b473414)

  • (es/minifier) Add logging (#4156) (97dfcb9)

Refactor

  • (css/prefixer) Rename crate (#4159) (7817547)

  • (es/lints) Use util for parens (#4167) (2a9cb2d)

Testing

  • (es) Organize tests (#4129) (ede6e02)

[1.2.160] - 2022-03-22

Bug Fixes

  • (common) Fix the line number of errors (#4082) (57802cf)

  • (es/codegen) Support multiline comments in return stmt (#4102) (552f16d)

  • (es/codegen) Emit decorators on class methods (#4103) (9b64a69)

  • (es/codegen) Fix codes related to sourcemap (#4106) (61f1a37)

  • (es/compat) Visit non-method properties in a nested object literal (#4094) (f5b9600)

  • (es/compat) Fix regression of es2015 (#4119) (154d443)

  • (es/minifier) Consider side effects while lifting sequences (#4116) (4a9817f)

  • (es/parser) Allow parentheses in assignment target (#4105) (d38117d)

  • (es/parser) Make let a reserved word in strict mode (#4113) (9a8fc27)

  • (es/typescript) Collect all bindings in strip (#4118) (13b2f38)

Features

  • (es/ast) Add raw to Str (#4071) (634d732)

  • (es/lints) Implement valid-typeof rule (#4095) (9ceefa7)

  • (es/lints) Implement use-isnan rule (#4080) (dd862ba)

  • (es/minifier) Implement more evaluation rules (#4030) (c6f8742)

Miscellaneous Tasks

Testing

  • (es/codegen) Add a test for fixed issue (#4121) (95c572f)

[1.2.159] - 2022-03-19

Bug Fixes

  • (api/rust) Exclude test files from rust packages (#4091) (533f756)

  • (common) Fix handling of input source maps (#4086) (b716210)

  • (es/compat) Visit generated codes from arrow (#4090) (cb0881c)

  • (es/compat) Revert wrong fix of arrow (#4093) (0d6bd81)

  • (es/module/cjs) Fix conflict of a local export and exports-alls (#4089) (6ac7934)

  • (es/resolver) Fix handling of decorators (#4084) (f662298)

Features

  • (es/lints) Implement no-new-symbol rule (#4076) (b39e345)

  • (es/module/cjs) Support import.meta.url (#4087) (d0f687b)

Testing

  • (es/parser) Add a test for a fixed issue (#4085) (792ab2c)

[1.2.158] - 2022-03-18

Bug Fixes

  • (css/prefixer) Reduce the number of vars in debug build (#4078) (4af5e6d)

  • (es/helpers) Fix decorator helper script (#4072) (55cfad1)

  • (es/modules) Fix sourcemap, really (#4074) (22d005e)

  • (es/react) Fix _createElement (#4070) (bb08354)

Features

  • (es/modules) Support namespaced reexports (#4073) (9458f08)

Miscellaneous Tasks

  • (repo) Auto-lock outdated issues and PRs (#4066) (ed7a5e5)

[1.2.157] - 2022-03-17

Bug Fixes

  • (es/ast) Revert removal of definite in PrivateProp (#4051) (bbe8f3d)

  • (es/codegen) Fix codegen of string literals (#4037) (bd444c0)

  • (es/codegen) Fix sourcemap (#4062) (9310c39)

  • (es/helpers) Add missing export for classPrivateFieldLooseKey (#4045) (3125bba)

  • (es/helpers) Export classPrivateFieldLooseKey as default (#4047) (025c921)

  • (es/helpers) Fix the name of _classPrivateFieldLooseBase (#4061) (f8a3849)

  • (es/parser) Allow nested ambient context in .d.ts files (#4060) (ffcb6ce)

  • (plugin/runner) Make build pass for wasm32 (#4056) (5c84fe5)

Features

  • (cli) Enable plugins for swc_cli (#4059) (fefb587)

  • (css/prefixer) Support more properties (#4055) (f2517a3)

  • (es/lints) Implement yoda rule (#3886) (833958b)

  • (node-swc) Add libc field in Linux platform packages (#4046) (db9b988)

  • (node-swc) Embed target triple string (#4058) (5a2a603)

[1.2.156] - 2022-03-16

Bug Fixes

  • (es) Sort spans while preserving comments (#4011) (b337c2e)

  • (es/compat) Change pass ordering of es2015 (#4029) (e19a60a)

  • (es/decorator) Remove noop_fold_type (#4022) (0c8c3d7)

  • (es/decorator) Insert initializer to constructor with body (#4028) (0c76696)

  • (es/helpers) Inject helpers for scripts (#4025) (73c91d3)

  • (es/lints) Fix false-positive of duplicate-exports (#4041) (ba1c854)

  • (es/modules) Use correct span for ExportAlls (#4038) (834cd4f)

  • (es/parser) Report an error if LeftHandSideExpression is invalid (#4001) (f8d6127)

  • (es/parser) Allow building with stable rustc (#4024) (25e5ccc)

  • (es/parser) Emit an error for multiple constructors with body (#4031) (120d2a5)

  • (node-swc) Disable logging of warn level by default (#4033) (bba5a33)

Features

  • (cli/compile) Support out-file (#4016) (629709e)

  • (css) Supports more color notations (#4009) (a4bc092)

  • (css/prefixer) Implement more rules for prefixer (#4013) (4f6f244)

  • (es/minifier) Drop noop calls (#4019) (be09ea6)

  • (es/transforms/base) Add paren_remover (#4034) (3a4704f)

Miscellaneous Tasks

  • (ci) Make bump-command check lazy (#4018) (c27b84c)

  • (ci) Fix auto-rebase script (9b8b111)

  • (ci) Revert package scripts to fix publish action (#4039) (eee8e0f)- general: Fix CI (da1fd03)

Refactor

  • (es/minifier) Cleanup (#4020) (3173047)

  • (plugin/runner) Split modules and introduce feature flags (#4035) (dab2002)

Testing

  • (es) Add tests for fixed issues (#4036) (71f7cf2)

Build

  • (tsconfig) Set tsbuildinfo filename (#4042) (a1308c9)

[1.2.155] - 2022-03-14

Bug Fixes

  • (common) Don't use None as source while generating source maps (#4007) (0ad13d9)

  • (css/codegen) Fix source maps (#3997) (ece8d96)

  • (es) Merge jsc.loose and jsc.assumptions (#3990) (3590ea2)

  • (es/resolver) Use correct context for identifiers after type parameters (#4000) (87a3c1c)

Documentation

  • (api/rust) Add examples (#4002) (dac84b9)

  • (api/rust) Add an example for generating code and sourcemap (#4005) (f650ca6)

Features

  • (common) Implement a pretty error reporter (#3946) (40b8a4e)

  • (css/parser) Improve error reporting (#3999) (96d6f37)

  • (es/minifier) Implement more rules for arrows (#3992) (64ca5ba)

  • (es/minifier) Compress more comparisons (#3996) (a23af2d)

Miscellaneous Tasks

  • (ci) Invoke yarn before publishing (743a5da)

  • (es/preset-env) Track .json files to make cargo happy (bd0fcb9)- general: Update linguist (#3991) (0312292)

Performance

  • (es/minifier) Refactor base54 (#3989) (04db7e2)

  • (es/minifier) Use Vec<u8> as a buffer for base54 (#3993) (f7b212b)

Testing

  • (*) Print diagnostics to stderr while testing (#4003) (ee9a841)

  • (es) Add an execution test system (#3994) (b22d084)

  • (es) Add auto-closable tests (#3995) (dabc492)

Build

  • (cargo) Set workspace default members (#3978) (560c81b)

[1.2.154] - 2022-03-12

Bug Fixes

  • (es) Change error message as it can be misleading (#3982) (48f2fd8)

  • (es/preset-env) Fix compilation issue (#3972) (7ebfcfa)

  • (es/preset-env) Publish builtin.json (#3973) (858372f)

  • (es/preset-env) Move out finished proposals (#3970) (502f934)

  • (preset-env) Use core-js-compat and @babel/compat-data directly (#3968) (487273f)

Features

  • (*) Update dependencies (#3964) (1206c84)

  • (css/codegen) Fix source maps and ast defs (#3974) (516dbc6)

  • (css/prefixer) Prefix more properties (#3976) (4a9a5ff)

  • (es/lints) Mark catch params as binding patterns while checking duplicates (#3981) (f28134f)

Miscellaneous Tasks

  • (ci) Skip unnecessary package for the benchmark (#3980) (485dc54)

  • (es/parser) Add some inline attributes (#3969) (6a6c322)

  • (es/preset-env) Use js script for copying files (#3986) (83722df)

Performance

  • (common) Use fxhash everywhere (#3985) (db60291)

  • (es/minifier) Make mangler faster by merging hash sets into one (#3983) (107c91d)

  • (es/minifier) Use fxhash for integers (#3984) (67e6154)

  • (es/minifier) Merge hashmap for scoping before checking (#3988) (1beecce)

Testing

  • (es) Add tests for fixed issues (#3987) (073d847)

[1.2.153] - 2022-03-11

Bug Fixes

  • (api/rust) Fix transform comment api (#3962) (fcbd3c5)

  • (es) Adjust tracing span level (#3911) (ca071fb)

  • (es/codegen) Fix sourcemap issue caused by reserved BytePos values (#3948) (e8018c5)

  • (es/compat) Refer this in constructor when super_is_callable_constructor is set (#3944) (de8a711)

  • (es/lints) Don't visit types while collecting const (#3967) (c6b5371)

  • (es/minifier) Preserve fuction parameters used for template literals in evaluate and reduce_vars (#3949) (91a302a)

  • (es/parser) Parse if-else chain iteratively (#3961) (76e6468)

  • (node-swc/types) Add reserved to TerserMangleOptions (#3959) (70a68a7)

Features

  • (css/codegen) Support source map (#3958) (5a6ebd3)

  • (es) Add an option to preserve all comments (#3815) (c5a0c9a)

  • (es/lints) Refine error message (#3952) (579aeb7)

[1.2.152] - 2022-03-10

Bug Fixes

  • (es) Don't create .swc if not required (#3937) (46e9d3f)

  • (es/compat/es2015) Fix span handling of arrow and classes (#3921) (12b8606)

  • (es/minifier) Skip exported vars while collapsing vars (#3928) (cc564ff)

  • (es/module) Make exported vars follow specification (#3906) (534fc52)

  • (es/module) Fix exported vars with bigint values (#3909) (8559fc9)

  • (es/module) Use correct return values for suffix update expressions (#3927) (dc457b4)

  • (es/module/cjs) Allow re-exports to be lazy (#3856) (f575b1b)

  • (es/parser) Fix the logic for token contexts (#3926) (4b4aef3)

  • (es/transform/optimization) Prevent inlining of vars used as RHS in logical expressions (#3907) (782a874)

  • (es/typescript) Remove imports used in interfaces and type signatures (#3893) (5c92b2d)

  • (wasm) Fix handling of swc_common::GLOBALS (#3936) (45a4374)

Features

  • (common) Align stable_hasher to latest rustc (#3895) (372f298)

  • (css/lints) Implement custom-property-no-missing-var-function rule (#3890) (19ececc)

  • (css/lints) Implement no-duplicate-at-import-rules rule (#3833) (59c84ac)

  • (css/parser) Improve error recovery (#3901) (6f781c3)

  • (css/prefixer) Implement more prefixing rules (#3905) (b25c479)

  • (css/prefixer) Handle more properties (#3919) (c2b9e1c)

  • (css/prefixer) Implement more rules (#3933) (62ab179)

  • (es/compat) Add tracing support to remaining compat transforms (#3904) (bd0a921)

  • (es/compat) Add pure comments for class fields keys (#3939) (112f428)

  • (es/fixer) Remove extra parens around IIFE in statements (#3918) (7cfa930)

  • (es/minifier) Remove pure calls (#3925) (bd838ac)

  • (es/minifier) Improve dropping of unused vars (#3923) (9e4dea6)

  • (es/parser) Report errors for non-abstract members in an abstract class (#3917) (16182d5)

  • (es/parser) Relax MSRV requirement (#3922) (a8ac7e3)

  • (es/testing) Print comments in test_fixture (#3920) (3d43a9b)

  • (preset-env) Update browserslist-rs (#3935) (aec1a54)

Performance

  • (*) Update tracing to improve performance of disabled spans (#3932) (86ea237)

  • (es) Add fast memory deallocator (#3910) (f3da349)

  • (es/minifier) Remove needless type parameter (#3897) (8b3aa6d)

  • (es/minifier) Make optimization of pure calls parallel (#3938) (f1ec862)

  • (es/parser) Improve performance by adjusting inlining (#3902) (4387813)

Refactor

  • (css/parser) Remove unused codes (#3903) (3a9af73)

[1.2.151] - 2022-03-07

Bug Fixes

  • (es/module) Revert fix for jest.spyOn (8e30d83)

Features

  • (es/compat) Enable set_public_method for TypeScript (#3884) (cb93883)

  • (es/fixer) Remove extra parens around iife in expression position (#3887) (9dd0105)

  • (es/lints) Support module/script mode in duplicate_bindings (#3880) (0181fbe)

Performance

  • (es/lints) Extract top level bindings only if the rule is enabled (#3889) (3e8efac)

  • (es/minifier) Add a fast-path to export merger (#3891) (a47eed7)

[1.2.150] - 2022-03-06

Bug Fixes

  • (es/module) Fix jsc.paths (#3879) (a65755f)

  • (es/parser) Fix parsing of const in ambient context (#3883) (aea59b8)

[1.2.149] - 2022-03-06

Bug Fixes

  • (css/lints) Allow empty @layer at-rule before @import at-rule (#3842) (90fdbab)

  • (es/lints) Ignore identifiers used as types while checking for duplicate bindings (#3869) (d10e662)

  • (es/minifier) Don't remove comments if compress is not configured (#3866) (e70c9d8)

  • (es/module) Fix jest.spyOn (#3845) (9546eef)

  • (es/module) Visit the value of class properties (#3877) (6a005fc)

  • (es/parser) Use unicode id instead of xid (#3867) (4426250)

  • (es/parser) Allow await in non-strict mode (#3871) (f757163)

Features

  • (cli) Setup subcommands for the features (#3858) (367a57d)

  • (css) Improve error recovery (#3853) (c84bf13)

  • (css/lints) Allow using regex in ignore list (#3855) (dc0de58)

  • (css/minifier) Compress @import at-rule (#3850) (ccfb4bf)

  • (es/compat) Implement loose mode for async_to_generator (#3870) (c7f2bdb)

  • (es/minifier) Implement pure_getters partially (#3872) (a264360)

  • (es/module/cjs) Support regex-based patterns for lazy config (#3704) (1f70fa6)

  • (es/transform) Unify logic for handling class properties (#3766) (6f076e4)

Performance

  • (es) Filter logs for cranelift out (#3801) (225f9a7)

  • (es/ast) Implement Clone without inline for some enums (#3878) (3b04789)

  • (es/compat) Add tracing support to transforms for from es2017 to es2019 (#3844) (a933db5)

  • (es/compat) Add tracing support for es2015 transforms (#3857) (cd8bb0f)

  • (es/transform) Use SingleThreadedComments for transform (#3847) (73ec0b3)

Testing

  • (es) Add a test for a fixed issue (#3873) (0ab3263)

  • (es) Add tests for fixed issues (#3874) (2605e13)

  • (es) Add tests for fixed issues (#3875) (8d3c9d3)

  • (es/transform/jest) Ensure that sourcemap is working (#3864) (fc87f43)

  • (swc) Use external helpers for reference testing (#3865) (8400708)

[1.2.148] - 2022-03-04

Bug Fixes

  • (css/codegen) Fix codegen of preserved tokens (#3819) (7ba5861)

  • (css/codegen) Fix the output of SimpleBlock (#3838) (e3a5c14)

  • (css/parser) Fix parsing of ; in values (#3821) (30cd29b)

  • (es/compat) Fix block scoping of variables (#3826) (406b8ea)

  • (es/hygiene) Fix renaming bugs (#3824) (043fba2)

  • (es/minifier) Preserve more variables (#3805) (89388e6)

  • (es/minifier) Don't reorder unnecessarily (#3817) (8a468f7)

  • (es/minifier) Support declaring multiple bindings with the same name (#3837) (0fc819e)

  • (node-swc) Correctly close trace spans after completion (#3811) (ffb2ee8)

  • (node-swc) Fix handling of OptionalChainingExpression in Visitor (#3809) (4d123c3)

  • (node-swc/types) Add a missing field of ExportNamedDeclaration (#3822) (bde7577)

Features

  • (config) Add a dedicated cached regex (#3832) (efc6741)

  • (css) Support color functions (#3836) (3df887c)

  • (css/lints) Add font-family-no-duplicate-names rule (#3818) (2d273d6)

  • (css/lints) Implement color-hex-alpha rule (#3829) (818b408)

  • (css/minifier) Compress more declarations (#3840) (0db6915)

  • (css/parser) Improve error recovery (#3810) (f969f8c)

  • (css/parser) Improve error recovery (#3828) (fbb98aa)

  • (es/lints) Implement radix rule (#3651) (f6b4bbe)

  • (es/minifier) Drop more function parameters in strict mode (#3814) (789eb7b)

  • (es/minifier) Improve sequential inlining (#3820) (364532e)

  • (es/minifier) Implement more rules (#3841) (260c2a8)

Miscellaneous Tasks

  • general: Ignore linguist detection for CSS test files (#3831) (8755ce1)

Performance

  • (es) Use Mutex from parking_lot (#3830) (351b814)

  • (es/parser) Remove duplicated instantiations of Parser to reduce binary size (#3813) (f5103a7)

Testing

  • (es/compat) Organize tests (#3825) (814dcc0)

[1.2.147] - 2022-03-02

Bug Fixes

  • (es/compat) Initialize class fields as a last step (#3767) (11bf29f)

  • (es/minifier) Disable some operations for asm.js codes (#3572) (e7f7f69)

  • (es/minifier) Fix inlining logic (#3776) (cfc0363)

  • (es/minifier) Preserve unresolved references (#3780) (73cab63)

  • (es/minifier) Fix optimizations of terminating expressions (#3794) (8beaa20)

  • (es/react) Catch refresh directives widely (#3791) (5ae907f)

  • (es/react) Fix logic for extracting refresh comments (#3796) (b485b5a)

  • (es/typescript) Transform this in TypeScript classes (#3764) (5f3f9ef)

  • (node-swc/cli) Correctly expose swcx entrypoint (#3784) (95ecc01)

Documentation

  • (adr) Add adr-00002 for event trace profiling (#3787) (3c1c5d0)

Features

  • (css/ast) Union Value and ComponentValue (#3804) (3ec45a6)

  • (css/lints) Add CSS linter (#3765) (66c6cae)

  • (css/lints) Add selector-max-combinators rule (#3789) (e389bef)

  • (css/minifier) Convert more length (#3769) (500d62c)

  • (es/codegen) Optimize output of new expressions without arguments (#3800) (e1b13eb)

  • (es/compat) Optimize handling of literals in computed property names (#3756) (8ed4d2f)

  • (es/compat) Add tracing support for es2022 transforms (#3785) (4d70482)

  • (es/compat) Use sequence expressions instead of iife in classes pass (#3773) (5b6beca)

  • (es/compat) Add tracing support for es2020 transforms (#3798) (8f41d7a)

  • (es/dep-graph) Add support for require.resolve (#3783) (19b84e7)

  • (es/minifier) Consider arguments while dropping unused assignments (#3775) (714e05e)

  • (es/module) Workaround stack overflow bug of JavaScriptCore related to too many exports (#3763) (ad0a853)

  • (es/modules) Support system js (#3659) (557a520)

  • (es/parser) Raise a syntax error on an invalid shorthand assignment (#3734) (2aa3b21)

  • (es/quote) Implement quasi quoter partially (#3155) (fe0ddcc)

  • (es/quote) Support variables (#3774) (e3c374b)

  • (plugin) Expose swc_ecma_quote (#3790) (bc60a6e)

  • (plugin/runner) Update wasmer to v2.2 (#3788) (99d536e)

Miscellaneous Tasks

  • general: Update rustc (#3768) (3798436)

Performance

  • (css/lints) Skip disabled rules (#3803) (0336029)

  • (plugin/runner) Optimize write_into_memory_view (#3797) (7fd0eee)

Refactor

  • (css/ast) Simplify AST types (#3753) (815a489)

  • (css/lints) Simplify error reporting API (#3781) (b8211da)

Testing

  • (css/parser) Add tests for selectors (#3770) (1651bcc)

  • (css/parser) Add css files for material design (#3777) (189707a)

  • (es/minifier) Prepare porting more rules from terser (#3779) (86072b5)

Build

  • (node-swc) Rename entrypoint to avoid artifact collision (#3806) (b485a2f)

[1.2.146] - 2022-02-27

Bug Fixes

  • (css) Fix processing of integers (#3752) (f258ee4)

  • (es/codegen) Fix escaping of unicodes in es5 (#3636) (dba90ea)

  • (es/helpers) Cast the result of the instanceof helper to boolean (#3728) (72c9e6c)

  • (es/parser) Handle trailing comma and bracket after an arrow function in conditional (#3685) (342dccc)

  • (es/typescript) Allow empty nested namespaces (#3754) (f5a3647)

  • (plugin/macro) Do not free guest memory twice (#3732) (d8b0166)- general: Fix(es/parser) Throw a syntax error for const without initializer in strict mode (#3742)

Co-authored-by: Donny/강동윤 kdy1997.dev@gmail.com (abc0572)

Features

  • (cli) Add tracing options for compile command (#3746) (41f92d2)

  • (css/ast) Support more selectors (#3729) (f5c5e77)

  • (css/ast) Allow more syntax for @supports at-rule (#3740) (9b92eba)

  • (css/ast) Improve type definitions for unicode ranges (#3757) (91cf965)

  • (css/minifier) Compress display (#3706) (8512719)

  • (es/codegen) Add sourcemap entry for injected semicolons (#3750) (0fd4fd2)

  • (es/compat) Implement loose mode for class_properties (#3722) (14155eb)

  • (es/dep-graph) Add TsImportEqualsDecl for DependencyCollector (#3758) (7de7eca)

  • (es/parser) Provide more api for reducing binary size (#3747) (47ccff8)

  • (macros) Add #[swc_trace] (#3738) (b4830b6)

  • (node-swc) Add experimental trace support in @swc/core (#3731) (a454996)

  • (plugin) Support tracing plugin execution (#3744) (5c29f15)

  • (visit) Allow using ?Sized as visitor (#3745) (b0b5d5d)

Miscellaneous Tasks

  • general: Skip CI for automated commits (#3760) (6d98d14)- general: Skip more actions for automated commits (#3761) (0ff4ad3)

Performance

  • (es/modules) Reduce usage of generics (#3743) (1094018)

  • (es/parser) Reduce usage of generics to reduce binary size (#3726) (e21579d)

Refactor

  • (es) Make compilation faster (#3749) (3d94465)

  • (es/transforms) Use recommended ast apis (#3735) (fd22379)

Testing

  • (css/parser) Add malformed hex color tests (#3762) (9f90882)

[1.2.145] - 2022-02-24

Bug Fixes

  • (es/codegen) Fix sourcemap of comments (#3723) (b8b0c92)

  • (es/compat) Throw an error if a private property is initialized multiple times (#3665) (b6434e5)

  • (es/parser) Emit an error for non-last rest element in an object pattern (#3675) (6a9d778)

  • (es/parser) Allow Expr::TsInstantiation in extends clause (#3696) (d499b8c)

  • (es/parser) Disallow using reserved words as an expression in typescript (#3697) (d6522f3)

  • (es/parser) Fix a typescript instantiation expression followed by EOF (#3699) (010fe04)

  • (es/parser) Fix the span of an export declaration containing a const enum (#3701) (4318a2e)

  • (es/parser) Don't attach comments to ; (#3720) (8b87bb4)

  • (es/typescript) Fix name of decorated classes (#3689) (1e49fcd)

  • (es/typescript) Support heterogeneous enums (#3721) (1761cab)

Features

  • (cli) Support stdin (#3688) (3cf3b20)

  • (css/minifier) Compress urange (#3668) (b1476d2)

  • (css/minifier) Compress lengths (#3698) (7079e88)

  • (css/minifier) Compress more properties (#3708) (cd95ac4)

  • (css/minifier) Compress alpha of values (#3707) (bff04b4)

  • (es/lints) Implement default-param-last rule (#3681) (e252265)

  • (es/typescript) Inline typescript enums (#3647) (1743302)

  • (node-swc) Expose the new swc_cli as a binary named swcx (#3684) (9cc094a)

Miscellaneous Tasks

  • (ci) Reduce CI time (#3719) (76ec275)

  • (clippy) Improve config (#3691) (e35d73a)

Refactor

  • (css/ast) Fix the type definitions for an plus b syntax (#3682) (321ee75)

  • (es) Improve ast apis (#3690) (135acf3)

[1.2.144] - 2022-02-22

Bug Fixes

  • (es/ast) Fix definition of Expr::TsInstantiation (#3657) (68a1551)

  • (es/parser) Allow type arguments inside optional chaining (#3653) (581b63c)

Features

  • (cli) Improve the template package.json for plugins (#3641) (f237aee)

  • (css/ast) Improve parsing of colors (#3680) (003a7b8)

  • (css/minifier) Compress selectors (#3623) (9e691fe)

  • (css/minifier) Compress declarations (#3649) (7d15316)

  • (css/minifier) Compress degrees to zero (#3664) (0b5f554)

  • (css/minifier) Compress urls (#3666) (fab6473)

  • (css/minifier) Compress transform functions (#3663) (1afbd1b)

  • (css/minifier) Compress frequency (#3669) (9b28d4d)

  • (es/ast) Support TypeScript Instantiation Expression (#3642) (61e711c)

  • (es/lints) Implement no-new rule (#3634) (7ff4cbc)

  • (es/lints) Implement no-bitwise rule (#3635) (5a9d0cf)

  • (es/lints) Add no-loop-func rule (#3630) (f4af363)

  • (es/lints) Implement no-empty-function rule (#3565) (319d501)

  • (es/minifier) Merge exports (#3643) (10adf1e)

  • (es/minifier) Improve name mangler (#3638) (e9fabd6)

  • (es/minifier) Drop more unused vars (#3656) (de6effc)

  • (es/preset-env) Upgrade browserslist-rs (#3670) (3199966)

  • (plugin) Pass NODE_ENV to plugins using the plugin context (#3677) (ca0a448)

Miscellaneous Tasks

  • (ci) Kill previous runs (#3678) (f733c9c)

  • (cli) Improve the plugin template (#3632) (0f1afcb)- general: Typo (#3646) (c5f0e87)

Performance

  • (es/minifier) Parallelize join_vars (#3655) (da2c77d)

Refactor

  • (es/ast) Change definition of optional chaining expressions (#3645) (2cb66ae)

  • (preset-env) Extract common logic for browserslist support (#3674) (b1d2470)

Build

  • (cargo) Use lld for windows-x64 (#3683) (82914d4)

  • (swc) Remove unused dependencies (#3673) (210f17a)

[1.2.143] - 2022-02-19

Features

  • (es/lints) Implement no-restricted-syntax rule (#3607) (72343ba)

  • (es/minifier) Treat !0 as a literal while inlining (#3631) (d2c9441)

Performance

  • (es/minifier) Fix performance bug of the mangler (#3633) (fd0e952)

[1.2.142] - 2022-02-18

Bug Fixes

  • (css) Fix recovery mode for functions (#3600) (5420bcc)

  • (css/parser) Fix parsing of component values (#3611) (b7dcccc)

  • (es) Pass FileName::Custom to plugins (#3578) (df69930)

  • (es/compat) Handle super and new.target in class properties (#3594) (3191741)

  • (es/lints) Use kebab-case for configuration (#3590) (71a94b1)

  • (node-swc/types) Fix experimental config options (#3603) (2b5eba1)

  • (plugin) Fix caching of wasm modulee (#3616) (05aecf5)

  • (swc_common) Fix names of proxied functions (#3608) (e863f9d)

Documentation

  • (api/rust) Fix rustdoc (#3620) (4d5ba55)

  • (swc_common) Document error reporting using HANDLER (#3605) (9df0d7c)

Features

  • (api/rust) Improve error messages for wrong usages of scoped thread-local variables (#3606) (798ef13)

  • (cli) Initialize compile command (#3602) (5ed3f3a)

  • (css/ast) Use SimpleBlock for @keyframes (#3577) (a20ed34)

  • (css/codegen) Improve minification of selectors (#3624) (8271566)

  • (css/minifier) Remove empty qualified rules and at-rules (#3597) (8c9b154)

  • (css/minifier) Implement the rule for easing functions (#3615) (8e06b2a)

  • (es/compat) Check for duplicate private names and undefined private names (#3613) (5c03551)

  • (es/lints) Implement no-dupe-args rule (#3574) (3e29b73)

  • (es/lints) Allow using number as an error level (#3593) (08c343b)

  • (swc) Add $schema and utf8-bom support for .swcrc (#3622) (3615f41)

Miscellaneous Tasks

  • (ci) Fix the script for CHANGELOG.md (cbe87db)

Refactor

  • (node-swc/types) Provide typed configuration for plugins (#3584) (07485d3)

Testing

  • (css/codegen) Add tests for custom properties in at-rules (#3596) (b019165)

  • (es/modules) Add a test for a fixed issue (#3586) (038e7f8)

  • (es/parser) Add a test for #2417 (#3588) (a2f9c88)

  • (es/typescript) Add a test for #2670 (#3589) (f469e65)

Build

  • (swc) Bump the version of parking_lot (#3604) (5061101)

[1.2.141] - 2022-02-16

Bug Fixes

  • (es/lints) Fix duplicate-bindings for typescript (#3583) (786d016)

  • (node-swc/types) Change StringLiteral.has_escape to StringLiteral.hasEscape (#3581) (bf68155)

Features

  • (css/ast) Use SimpleBlock in more places (#3575) (e97074b)

  • (css/minifier) Compress contents of @keyframes at-rule (#3579) (803499c)

Miscellaneous Tasks

  • (ci) Don't run pr check for pushes (1bce557)

  • (ci) Make CI faster (55250e4)

  • (ci) Fix the auto-bump scripts (2d9735b)

  • (ci) Fix the auto-bump scripts (7ddd588)

  • (ci) Fix the auto-bump scripts (c775674)

  • (ci) Fix version of git-cliff (32bc17f)

  • (ci) Don't mark as a failure (6173bb8)

  • (ci) Fix the condition for cancel action (d66f701)

  • (ci) Skip instead of cancel (85caf29)

Refactor

  • (plugin) Remove direct dependency to once_cell (#3582) (88e07b2)

[1.2.140] - 2022-02-15

Bug Fixes

  • (es/compat) Allow destructuring assignment to an object property (#3544) (5802b62)

  • (es/compat) Fix destructing of const (#3545) (342c320)

  • (es/compat) Apply new.target before classes (#3555) (f1c7394)

  • (es/compat) Handle arrow parameters in class fields (#3556) (45b44b0)

  • (es/compat) Fix handling of constructor in classes (#3505) (0b16210)

  • (es/minifier) Fix analyzer (#3557) (ac1d405)

  • (es/minifier) Disable name mangler if eval is used (#3526) (bfc9897)

  • (es/utils) Keep arguments to super call (#3570) (f67796a)

Documentation

  • (plugin) Fix typo (#3547) (3fc16cd)

Features

  • (bot) Add auto-bump script (#3573) (a1e45c4)

  • (css/ast) Add ; to delimiters (#3551) (da36e90)

  • (css/ast) Use correct type for calc (#3549) (b311ace)

  • (css/ast) Use SimpleBlock for @document at-rule (#3564) (3399702)

  • (es/compat) Add loose mode for classes (#3474) (0f7a997)

  • (es/lints) Add this handling support to no-alert rule (#3515) (af82006)

  • (es/lints) Add allow config for no-console rule (#3517) (286b6c8)

  • (es/lints) Implement eqeqeq rule (#3513) (8d92050)

  • (es/lints) Implement no-empty-pattern rule (#3550) (f9fda27)

  • (plugin) Add PluginContext (#3568) (a96217f)

  • (plugin/runner) Improve resolver support for npm (#3566) (d6477a7)

Miscellaneous Tasks

  • (bot) Fix permission issue (bfb51f3)

  • (ci) Add a bot for auto-rebasing (#3560) (b1fc7a9)

  • (ci) Remove useless tests from the matrix (#3561) (47a81bd)- general: Fix auto-rebase script (d055711)- general: Fix auto-rebase script again (d3f1c4e)- general: Use GITHUB_TOKEN for auto-rebasing (1c6e9ef)- general: Fix CLA issue of auto-rebase script (59233d5)

Performance

  • (es/optimization) Replace map_with_mut with proper implementation (#3539) (6d132ca)

Refactor

  • (css/ast) Rename tokens to match spec (#3553) (aed622b)

  • (css/parser) Remove parse_values, which is not used (#3552) (d5aee47)

Testing

  • (css/codegen) Add tests (#3563) (08dd695)

  • (css/parser) Add a test for a custom function name (#3554) (f252dfb)

Build

  • (*) Dedupe once_cell (#3567) (ad6f24a)

[1.2.139] - 2022-02-12

Bug Fixes

  • (cli) Update the plugin template for pinned dependencies (#3538) (05cf2e9)

  • (css/ast) Use SimpleBlock in more types (#3535) (cfb2248)

  • (es/modules) Use correct StrKind after rewriting import path (#3489) (ff6eb27)

  • (es/modules) Hoist named exports (#3479) (fa0216d)

  • (node/helpers) Fix isNativeReflectConstruct (#3530) (d14d3eb)

  • (plugin) Allow testing (#3542) (fbe9196)

Documentation

  • (plugin) Fix install command (#3541) (72b3197)

Features

  • (cli) Add a command for scaffolding a new plugin (#3536) (6ed089e)

  • (css) Support urange syntax (#3491) (cbe302b)

  • (css/minifier) Implement more rules (#3522) (69cfe39)

  • (css/parser) Improve error recovery (#3486) (48e5b90)

  • (css/parser) Implement more parser logic for nth selectors (#3532) (fcbc2ff)

  • (css/parser) Implement more error recovery (#3534) (547eba5)

  • (es/lints) Implement dot-notation rule (#3481) (5bb6bd7)

  • (es/lints) Implement no-use-before-define rule (#3456) (205b76e)

  • (es/minifier) Implement reserved mangle option (#3476) (5488159)

  • (es/minifier) Drop useless assignments (#3528) (a7f0e84)

  • (plugin) Implement proxy for Mark and SyntaxContext (#3511) (bc25026)

  • (swc/plugin) Implement proxy for Mark::fresh (#3492) (494b4c8)

Miscellaneous Tasks

  • (build) Disable LTO for local builds (#3514) (80ed69d)

  • (build) Remove version pinning of parking_lot_core (#3537) (a4d914d)

  • (ci) Remove cargo-uttil from dependency (#3543) (068a408)

  • (crates) Use bot account for publishing commits (c10cbc4)

  • (crates) Use bot account for commiitter (edc46cc)

Performance

  • (es/minifier) Remove useless operations like eager call to .span() (#3512) (8dab3d9)

Refactor

  • (common) Cleanup & rustfmt (#3495) (9b76783)

  • (css/ast) Rename types to match specification (#3484) (460f846)

  • (css/ast) Remove Tokens in favor of Vec<TokenAndSpan> (#3507) (92a3cb9)

  • (css/ast) Unify SimpleBlock and Block (#3519) (57f6a58)

  • (css/ast) Unify SimpleBlock and Block completely (#3531) (37c49e8)

  • (css/parser) Refactor codes related to simple blocks (#3506) (4e124c7)

  • (css/parser) Refactor code for error recovery (#3508) (2d997b3)

Testing

  • (css/codegen) Add tests for multiple keyframe selectors (#3509) (ebd71d5)

  • (css/parser) Add tests from postcss (#3488) (04782ae)

  • (css/parser) Add some tests from postcss (#3501) (8b438ea)

  • (es/minifier) Add snapshot testing for the analyzer (#3529) (73e9185)

[1.2.138] - 2022-02-08

Bug Fixes

  • (es/minifier) Make sequences less aggressive (#3480) (292add7)

Features

  • (css) Add support for @property at-rule (#3470) (fd5668c)

  • (css/ast) Add types for @counter-style at-rule (#3469) (e6f4fbf)

  • (css/ast) Add types for all dimensions (#3477) (dc939c6)

  • (es/parser) Disallow assignment to optional chaining expressions (#3483) (26565b1)

  • (plugin) Support global HANDLER in the plugin context (#3478) (d473a65)

Miscellaneous Tasks

  • (es) Fix clippy warnings (#3482) (8bf5cf4)

  • (repo) Configure kodiak (#3485) (cf8aa05)

[1.2.137] - 2022-02-07

Bug Fixes

  • (css) Fix parsing of @page at-rule (#3356) (4853821)

  • (css/ast) Fix type definitions for @document at-rule (#3468) (df08e4c)

  • (css/parser) Report errors of at-rules (#3461) (e732250)

  • (es/compat) Handle private fields in nested classes (#3431) (01500a5)

  • (es/compat) Handle initializer hole in array patterns (#3442) (3bb2a6c)

  • (es/compat) Fix legacy decorator pass (#3459) (4f5e87b)

  • (es/fixer) Handle more expressions in the super class position (#3452) (032f397)

  • (es/minifier) Fix codemirror (#3462) (5812c3c)

  • (es/minifier) Fix mapbox (#3463) (0371c41)

  • (es/modules) Allow using a dynamic import with an expression from another import (#3450) (745604b)

  • (es/parser) Fix parsing of decorators (#3449) (5a806c5)

  • (es/resolver) Fix handling of for statements (#3446) (2af5096)

Features

  • (css/ast) Improve types related to url tokens (#3444) (49564d9)

  • (css/codegen) Implement minification of hex colors (#3453) (eeedd71)

  • (css/codegen) Implement minification of identifiers (#3466) (81850c2)

  • (css/codegen) Improve minification for page rules (#3467) (0ca036a)

  • (css/lexer) Implement error recovery for functions (#3445) (f1410fc)

  • (es/lints) Implement prefer-regex-literals (#3399) (8166275)

  • (es/lints) Implement linter for quotes of string literals (#3443) (5d6143a)

  • (es/parser) Add an option to allow super outside of class methods (#3427) (cc185f0)

Miscellaneous Tasks

Refactor

  • (css/ast) Refactor types related to @keyframes at-rule (#3441) (5c1b021)

  • (css/ast) Change AST for !important (#3440) (38879de)

  • (css/ast) Refactor types related to selectors (#3460) (cd87d96)

  • (css/ast) Remove unused types (#3465) (69660fd)

Testing

  • (css/parser) Add more tests for the selector parser (#3455) (479b509)

  • (es) Update tsc test suite (#3448) (8b7c38c)

  • (es/parser) Fix crlf (#3451) (397a96a)

[1.2.136] - 2022-02-03

Bug Fixes

  • (css) Allow empty @media at-rule (#3404) (75a14f9)

  • (css/parser) Fix parser logic related to case insensivity (#3382) (3ded88b)

  • (css/parser) Fix bugs related to url (#3403) (3c8d985)

  • (es/codegen) Fix bugs (#3436) (ea8dfd8)

  • (es/compat) Add the missing span in optional_chaining (#3384) (9eb7773)

  • (es/minifier) Fix evaluator (#3391) (38c2499)

  • (es/modules) Allow using dynamic import with a name from another import (#3390) (1dcc188)

  • (es/modules) Fix span of imports (#3418) (2c99ca1)

  • (swc) Run resolver before everything (#3400) (cebc5dc)

Features

  • (css) Improve codegen where minify: true (#3414) (30c29a3)

  • (css/ast) Add / to the delimiters (#3402) (2dc31d9)

  • (css/codegen) Implement minify: true (#3369) (0537ef1)

  • (css/codegen) Improve minification of numbers (#3423) (340844a)

  • (css/parser) Improve selector parser (#3386) (c73835b)

  • (css/parser) Improve parsing of math functions (#3415) (1b1cae0)

  • (es/codegen) Improve compression of numbers (#3425) (e8b64a9)

  • (es/lints) Implement no-debugger rule (#3398) (9dec923)

  • (es/lints) Add no-alert and a feature gate (#3394) (5cbe4fe)

  • (es/minifier) Implement drop_console (#3392) (91d7800)

Miscellaneous Tasks

  • (repo) Add clippy to git push hook (#3383) (78e83a3)

Performance

  • (node-swc) Speed up parse and parseFile (#3380) (0359deb)

Refactor

  • (css/ast) Refactor delimited values (#3397) (b31619d)

  • (css/ast) Use Dimension instead of UnitValue (#3401) (1904944)

  • (css/ast) Use Color instead of HashValue (#3411) (6b921ca)

  • (css/ast) Rename property to name (#3410) (eeedd9a)

  • (es/minifier) Remove unused crates (#3395) (74b4330)

  • (es/parser) Flatten tests to make git faster (#3393) (839d0ac)

Testing

  • (css/codegen) Add more tests (#3405) (64383e3)

  • (css/codegen) Verify AST is not broken after minification (#3430) (73efd72)

  • (swc) Add tests (#3435) (9e4cea0)

[1.2.135] - 2022-01-27

Bug Fixes

  • (css) Fix the type definition of @support at-rules (#3330) (34943ff)

  • (css) Fix @keyframes at-rule (#3331) (f89ffa6)

  • (css) Fix @supports at-rule (#3329) (9f38060)

  • (css/parser) Fix parsing of at rules (#3328) (506a310)

  • (es/block-scoping) Pop scope correctly on early returns (#3360) (b1a8db6)

  • (es/compat) Fix regression of destructuring (#3326) (6d1ad36)

  • (es/compat) Handle nested functions in private_field (#3355) (29aaac1)

  • (es/loader) Add an option to resolve symlinks with true as a default (#3340) (afdb168)

  • (es/minifier) Consider capturing while inlining (#3322) (4f23d65)

  • (es/minifier) Don't inline a var if the initializer is reassigned (#3333) (d52a1f3)

  • (es/minifier) Respect block scoping while negating if statements (#3344) (6921ffb)

  • (es/minifier) Prepend/append correctly (#3367) (703972d)

  • (es/minifier) Improve minifier (#3350) (68e9017)

  • (es/module) Remove .jsx file extension (#3334) (b2bf38d)

  • (es/typescript) Handle typescript enums with string values (#3339) (da709fe)

  • (swc) Respect jsc.experimental.keepImportAssertions (#3352) (d9dc2b9)

Documentation

  • (contributing) Fix formatting (#3376) (90cf073)

Features

  • (css/ast) Add Ratio, which is defined by spec (#3335) (c7e5fae)

  • (css/ast) Add types for dashed identifiers and @color-profile at-rules (#3364) (dfa0286)

  • (css/parser) Improve parsing of urls (#3362) (50521d8)

  • (es/bugfix) Add bugfix-safari-id-destructuring-collision-in-function-expression (#3109) (d1c90a4)

  • (es/codegen) Emit comments of Module and Script (#3358) (fcb7288)

  • (es/lints) Implement "no-console" rule (#3269) (9872137)

  • (es/minifier) Handle array literals in sequences (#3348) (8007b2d)

  • (es/preset-env) Upgrade browserslist-rs (#3375) (d3d754b)

  • (plugin) Pass host context to plugins for diagnostics emission (#3359) (a8debc1)

Miscellaneous Tasks

  • (ci) Update thread_local (#3357) (a635e9f)

  • (ci) Fix FreeBSD build (#3379) (464c15b)

Performance

  • (node) Avoid cloning options (#3325) (8a76935)

Refactor

  • (css/ast) Merge several kinds of blocks into a single type (#3336) (c664eaf)

  • (css/ast) Fix type definitions related to @import at-rule (#3351) (7787f90)

  • (css/ast) Rename PercentValue to Percent (#3363) (6fc7562)

  • (es/minifier) Merge execution tests into a file to make git faster (#3377) (7ef3bfa)

  • (plugin) Remove multivalue polyfill (#3346) (4386498)

[1.2.133] - 2022-01-20

Bug Fixes

  • (css) Fix parsing of media queries (#3318) (0723ee2)

  • (es/minifier) Don't inline functions used as arguments (#3320) (57204e3)

Documentation

  • (repo) Update contributing docs (#3298) (5af79f6)

Miscellaneous Tasks

  • (rustc) Downgrade rustc (041bf00)

Build

  • (node-swc) Fix GLIBC < 2.18 compatible issues and android arm binary loading issue (#3314) (9608605)

  • (node-swc) Fix Windows arm64 build OOM (#3324) (c069c78)

[1.2.131] - 2022-01-19

Bug Fixes

  • (common) Use siphasher directly and upgrade transitive dependencies to avoid UB (#3299) (641265b)

  • (es/compat) Apply static_blocks before class_properties (#3292) (89235b8)

  • (es/minifier) Fix analysis of unary expressions (#3286) (b55ae4b)

  • (es/minifier) Inline into interpolations in tagged template literals (#3287) (fa5c063)

  • (es/minifier) Remove more side-effect-free expressions. (#3301) (18a11d7)

  • (es/minifier) Don't emit invalid code (#3302) (8e796cd)

  • (es/minifier) Fix logic for checking arguments (#3313) (1aa494b)

  • (es/minifier) Prevent infinite loop due to negation (#3310) (b4d21bf)

  • (es/resolver) Ignore names of jsx attributes (#3289) (9a89895)

Documentation

  • (swc) Document typescript::strip (#3305) (18cd98e)

Features

  • (es/compat) Use remove useless source map entries generated by classes (#3242) (2352920)

  • (es/minifier) Drop more expressions from parallel optimizer (#3303) (210ecf8)

  • (plugin) Add PluginError (#3300) (c6ffdc8)

Refactor

  • (es) Add visit_obj_and_computed macro (#3304) (9e636c7)

  • (es/minifier) Fix clippy warnings (#3312) (2891220)

Testing

  • (plugin/runner) Pin dependencies for the integration test (#3306) (7ba8a83)

[1.2.130] - 2022-01-17

Bug Fixes

  • (css/lexer) Resolve a TODO (#3260) (ade8ab8)

  • (es/ast) Update EsVersion::latest() (#3261) (6997851)

  • (es/minifier) Preserve side effects in correct position (#3263) (efd8671)

  • (es/parser) Throw an error when function body has use strict and paramaters is not simple (#3278) (6406b49)

  • (es/react) Fix createElement (#3277) (88a258a)

  • (es/resolver) Treat a switch statement as a block scope (#3275) (f4b3cb7)

  • (es/transforms) Fix this in async arrow class properties (#3252) (7c19e26)

  • (es/transforms) Remove unsafe new String("...") optimization (#3284) (162c1fe)

  • (es/transforms) Handle template literals within jsonify pass (#3282) (b76d1da)

  • (swc) Remove wrong-target (#3251) (0843f74)

Documentation

  • (adr) Configure adr and add 00001-plugin (#3249) (8652b2d)

Features

  • (css) Support @layer at-rule (#3258) (c195335)

  • (es/ast) Improve AST api for plugin authors (#3281) (9dd0647)

  • (es/compat) Use var for _len and args in rest parameters (#3267) (d3cc488)

  • (plugin/runner) Free allocated memory on errors (#3270) (66d1a92)

  • (plugin/runnner) Support wasm32-wasi targets (#3271) (a4c4974)

Miscellaneous Tasks

  • (ci) Configure clippy (#3250) (978de59)

Refactor

  • (*) Fix some clippy warnings (#3257) (15b604b)

  • (*) Cleanup (#3274) (357a350)

  • (es) More fix for clippy (#3280) (e8670b3)

  • (es/transforms) Cleanup (#3273) (2690742)

  • (es/utils) Merge the super field visitor with FnEnvHoister (#3279) (90a62bb)

Build

  • (node) Fix glibc issue on linux gnu arm (#3255) (2144271)

[1.2.129] - 2022-01-13

Bug Fixes

  • (es/compat) Transform &&= operator (#3225) (2e5150d)

  • (es/minifier) Fix handling of inlined call to a hoisted function (#3223) (78720c4)

  • (es/minifier) Fix optimization of assignment expressions (#3231) (12dd0a6)

  • (es/minifier) Fix bugs (#3238) (74fd353)

  • (es/parser) Fix span of ComputedPropName (#3234) (105cbc2)

  • (es/typescript) Remove rogue println (#3244) (282232c)

Features

  • (plugin) Don't serialize/deserialize needlessly (#3227) (a2f2b5a)

  • (plugin/macro) Add safe API for plugins based on a proc-macro (#3240) (432d5d3)

[1.2.128] - 2022-01-11

Bug Fixes

  • (es/helpers) Don't transpile _typeof helper (#3208) (54353a6)

  • (es/hygiene) Visit computed properties in usage analyzer (#3217) (cdb46cf)

  • (es/minifier) Disable inlining of expressions from collapse_vars (#3200) (69b5f79)

  • (es/minifier) Drop unreachable statements eagerly (#3204) (0105939)

  • (es/modules) Fix lazy import handling (#3211) (9565149)

Features

  • (es/ast) Use ModuleExportName for ExportNamespaceSpecifier (#3195) (432f877)

  • (es/ast) Update is-macro (#3226) (1edbf1a)

  • (es/compat) Implement object super (#3127) (b649d23)

  • (es/parser) Accept strings for import/exports (#3190) (3fb76f6)

  • (es/transforms) Add Assumptions (#3215) (42f7268)

  • (plugin) Pass serialized ast to a wasm file (#3199) (92de2c7)

  • (plugin) Allow multi-value for the plugin signature (#3216) (c9ded9b)

  • (plugin) Perform actual transforms in plugins (#3220) (7e7421e)

Miscellaneous Tasks

  • (es/minifier) Add scripts to extract tests automatically (#3212) (057fca4)

Refactor

  • (es/ast) Change types of member-like expressions (#3178) (f58b50b)

  • (es/compat) Preserve length of functions in async_generator (#3202) (5bee4e4)

Security

  • (repo) Fix crev integration (#3210) (70c2f3b)

[1.2.127] - 2022-01-06

Bug Fixes

  • (es/lints) Fix incorrect duplicate binding error (#3194) (913c82a)

  • (es/minifier) Fix bugs (#2955) (1c1c9f0)

  • (es/visit) Make noop_visit_type visit typescript nodes that executes at runtime (#3192) (517662c)

Features

  • (es/dep-graph) Improve DependencyDescriptor to combine import_assertions with dynamic_import_assertions (#3183) (e5e6e84)

  • (esdiff) Create a command to determine problematic file (#3181) (51c792e)

Miscellaneous Tasks

  • (*) Update rustc (#3185) (7d0a8a1)

  • (ci) Split cargo docs (#3187) (46949d3)

  • (ci) Fix publish scripts (3458e9f)

  • (ci) Fix publish scripts again (b292126)

  • (ci) Fix --cargo-flags (a20f5d9)

  • (ci) Use --cargo-flags in correct place (ef4ea2f)

  • (ci) Use RUSTFLAGS for linux (4cbe8d1)

  • (ci) Use more RUSTFLAGS (bf0acd1)

  • (ci) Fix musl (fef8449)

  • (ci) Fix aarch64-pc-windows-msvc (1ebbe62)

  • (ci) Change version of rustc (d901b62)

  • (ci) Fix publish script (#3197) (c34f1a9)

  • (ci) Remove redudant plugin test (e19fe7d)

Refactor

  • (dbg-swc) Rename esdiff to dbg-swc (#3189) (c758997)

  • (plugin) Add a loader for wasm-based plugin system (#3179) (fc4c670)

  • (plugin) Remove codes related to the plugin system based on abi_stable (#3188) (32d3342)

  • (plugin/runner) Avoid redundant filesystem reads (#3186) (b61c49f)

  • (plugin/runner) Replace wasm runtime (#3196) (c3895ca)

  • (plugin/runner) Reuse wasmer (28ff059)

[1.2.126] - 2022-01-03

Bug Fixes

  • (es/minifier) Fix comparison of objects, numbers and strings (#3172) (db51ce4)

  • (node-swc) Recover from ldd not found (1dfc2ee)

Features

  • (es/ast) Add ModuleExportName (#3048) (07c0489)

[1.2.125] - 2022-01-02

Bug Fixes

  • (es/compat) Visit all private class methods (#3150) (35b6461)

  • (es/compat) Fix length of async functions (#3136) (f78d005)

  • (es/compat) Fix new.target in class properties (#3156) (e112103)

  • (es/minifier) Fix for modules (#3170) (790c506)

  • (es/typescript) Fix handling of references in a TypeScript enum (#3163) (e02307d)

  • (es/typescript) Declare the exported variables in a namespace (#3162) (366dc0e)

  • (es/utils) Fix handling of new.target (#3145) (356082a)

Documentation

  • (es/ast) Improve rustdoc (#3142) (333acb5)- general: Update discord link (#3161) (fb20480)

Features

  • (es/ast) Add rkyv support (#3166) (bf751cb)

  • (es/codegen) Make the output for empty objects and empty statements pretty (#3171) (5296180)

  • (es/diff) Add a internal CLI program for debugging minifier (#3168) (1aa55e6)

Miscellaneous Tasks

  • (ci) Update github-action-benchmark (#3148) (5a3bdc9)- general: Add enhancement label to feature_request template (#3164) (360ad7b)

Performance

  • (es/ast/serde) Make deserialization faster (#3160) (7a83c0c)

Refactor

  • (*) Drop unused dependencies (#3138) (72c9636)

  • (*) Use 2021 edition (#3151) (194b3e9)

  • (bundler) Improve test suite (#3144) (8a1016f)

Testing

  • (es/parser) Add tests about null escape (#3147) (a4e8e53)

[1.2.124] - 2021-12-29

Bug Fixes

  • (es) Handle import assertions correctly (#3113) (c9adf03)

  • (es/compat) Fix handling of hoisted functions in regenerator (#3119) (ac78a52)

  • (es/compat) Fix private methods of a class (#3123) (1b6ac25)

  • (es/compat) Fix computed_properties (#3120) (27d3fd9)

  • (es/optimization) Fix inlining (#3132) (693c22a)

  • (es/parser) Support import assertions in specifier-less imports (#3134) (2f3ca22)

  • (es/renamer) Fix renamer (#3139) (43c8cda)

  • (es/utils) Fix is_valid_ident (#3133) (ec7e0ae)

  • (node-swc) Recover from ldd not found (#3125) (054a195)

Features

  • (es/preset-env) Upgrade browserslist-rs (#3122) (83f71c2)

Miscellaneous Tasks

  • (ci) Reduce CI time (#3128) (61cd7da)

Refactor

  • (es/react/fast-refresh) Use VisitMut (#3129) (f8f04e0)

Security

  • (repo) Configure cargo-crev (#3124) (cec325b)

[1.2.123] - 2021-12-26

Bug Fixes

  • (es/ast) Fix Ident::verify_symbol (#3108) (e5971f7)

  • (es/compat) Fix classes pass (#3107) (d923f89)

  • (es/compat) Fix destructuring (#3104) (9f5a8f7)

  • (es/compat) Fix handling of class methods with a big int as a key (#3118) (a1cb4a4)

  • (es/helpers) Fix decorators (#3105) (f66c2cd)

Features

  • (es/bundler) Add an option to disable tree-shaking (#3102) (d98a593)

  • (es/diff) Initialize a diff tool for ecmascript (#3101) (ff0b55b)

  • (node) Upgrade napi to v2 (#2958) (206da12)

Miscellaneous Tasks

  • (ci) Fix script for publishing (f51314c)

  • (xi) Fix publishing script (e0e7f74)- general: Fix package.json (999df43)

[1.2.122] - 2021-12-22

Bug Fixes

  • (es/compat) Fix handling of union of the legacy decorator pass (#3057) (938e544)

  • (es/loader) Prefer ESM (#3089) (ba2563f)

  • (es/loader) Update lru (#3092) (15cbe4f)

  • (es/transforms) Fix descturcturing (#3098) (df87c2b)

  • (es/typescript) Export destructured properties in typescript namespaces (#3084) (31dea3d)

Features

  • (cli) Setup packages for CLI (#3070) (2e89a4f)

  • (es/dep-graph) Add DependencyDescriptor::dynamic_import_assertions (#3095) (7d57eb2)

  • (es/lints) Implement simple validations (#2763) (f21af5b)

  • (es/preset-env) Upgrade browserslist-rs (#3069) (a1b315a)

  • (es/preset-env) Add ES2022 features to preset-env (#3072) (7beaabd)

  • (es/preset-env) Add .js to generated imports (#3077) (7d125f5)

  • (node) Report correct error when swc_v1 and swc_v2 is enabled at the same time (#3080) (f1b8126)

  • (node/core) Include noop swc binaries (#3088) (42046e1)

Miscellaneous Tasks

  • (node) Publish v1.2.122 (f4cc323)

  • (repo) Make git faster (#3075) (8afb5af)

  • (repo) Add section for the actual behavior to the issue template (#3100) (0472199)

  • (scripts) Use cargo profile instruments instead of cargo instruments (#3086) (d482d61)

Performance

  • (es/hygiene) Fix performance bug (#3090) (a81661c)

Refactor

  • (es/minifier) Use swc_timer (#3087) (0e4dce6)

Testing

  • (es/codegen) Add some tests for sourcemap (#3078) (0e58950)

[1.2.121] - 2021-12-19

Bug Fixes

  • (es/compat) Fix block_scoping (#3058) (a381fb8)

  • (es/compat) Transform an optional eval call as an indirect eval call (#3068) (ff1aab7)

  • (es/lexer) Don't report lexer errors while backtracking (#3051) (61e9b5f)

  • (es/lexer) Fix lexing of numbers with large exponent (#3061) (0c813ae)

  • (es/loader) Support fully-specified ESM import specifiers (#3050) (d5c7fb8)

  • (es/parser) Allow assignment assertions in typescript classes (#3047) (23a59db)

  • (webpack/ast) Fix webpackAST (#3040) (15ea98b)

  • (webpack/ast) Handle typescript (#3045) (24179bd)

  • (webpack/ast) Expose fields of AstOutput (#3046) (0892018)

Features

  • (es/parser) Report an error for export type * from "mod"; (#3064) (f1a2832)

Miscellaneous Tasks

  • (crates) Use interactive bump (276d74f)

  • (node) Publish v1.2.121 (806c9db)

Performance

  • (es/compat) Migrate regenerator to VisitMut (#3037) (29eb71a)

  • (es/parser) Improve performance (#3059) (b4d95b4)

Refactor

  • (es/ast) Change type or the key of ClassProp to PropName (#3038) (38955c0)

[1.2.120] - 2021-12-13

Bug Fixes

  • (css/parser) Fix lexing of value starting with - (#3011) (e0c8bbf)

  • (es/codegen) Fix sourcemap bug related to multi-line comments (#3023) (c415487)

  • (es/dep_graph) Fix parsing of import assertions (#3005) (819fc88)

  • (es/parser) Allow trailing comma in dynamic imports if import assertion is enabled (#3018) (b4c210d)

Features

  • (node-swc) Add cargo feature for v2 (#3019) (017392a)

Miscellaneous Tasks

  • (api/rust) Automate updating of change logs (4006d56)

  • (ci) Setup yarn cache (#3015) (69123dd)- general: Remove redundant dependencies (#3008) (cabf5a4)- general: Add changelog and pr template (#3017) (aab3326)

Performance

  • (es/compat) Migrate regenerator to VisitMut partially (#3007) (91d6343)

  • (es/compat) Migrate classes to VisitMut partially (#2995) (333b52c)

  • (es/compat) Migrate class helper to VisitMut (#3020) (d3ffc67)

Refactor

  • (es/ast) Move Id to swc_ecma_ast (#3004) (8340a86)

  • (es/parser) Make some verification logic optional (#3024) (7236a22)

Build

  • general: Use mocha for exec_ test instead of jest (#3009) (00d22b8)

Type

  • (node/swc) Allow null for NamedExportSpecifier.exported (#3010) (bdea89d)

[1.2.119] - 2021-12-10

Bug Fixes

  • (css) Fix stylis (#2987) (c8395bc)

  • (es/codegen) Fix sourcemap (#3003) (a3bd6ae)

  • (es/compat) Preserve constructor parameters (#2975) (f052a65)

  • (es/compat) Fix for synthesized template literals (#2994) (6a7ad92)

  • (es/minifier) Don't create top level variables (#2985) (4a7937d)

  • (es/react) Implement proper development handling (#2741) (ed704c9)

  • (es/transforms) Update helpers about array (#2970) (ae4bb42)

  • (es/typescript) Support declaration merging of exported enums and namespaces (#2982) (2cd1649)

  • (es/typescript) Fix enums which reference themselves (#3000) (c8c73cb)

  • (node/swc) Allow using custom bindings (#2983) (c02dd99)

  • (webpack/ast) Fix webpackAST (#2979) (4cf5852)

Features

  • (es/minifier) Print more informantion on infinite loops (#2976) (694d3c5)

Miscellaneous Tasks

  • general: Fix @swc/helpers (6996d7c)- general: Fix license issue (#3002) (0a637d6)

Performance

  • (es/compat) Migrate static_blocks to VisitMut (#2973) (32f9369)

  • (es/compat) Migrate class_properties to VisitMut (#2993) (a175606)

  • (es/compat) Migrate object_rest to VisitMut (#2997) (7ca1e17)

Refactor

  • (visit) Remove &dyn Node from Visit (#2984) (e48263b)

[1.2.118] - 2021-12-05

Bug Fixes

  • (es/hygiene) Reduce renaming (#2938) (4d993c2)

  • (es/parser) Drop outdated options (#2974) (1ea965c)

  • (es/parser, es/compat) Transform tagged template with invalid escape sequence (#2939) (d8c8641)

  • (es/typescript) Run resolver before typescript::strip (#2951) (67280b6)

  • (es/typescript) Transform namespace with multiple identifiers in name (#2952) (0a8a5a1)

  • (estree) Fix serialization of ObjectMethod (#2961) (c346f12)

  • (node/swc) Add baseUrl to JscConfig (#2968) (1f6d830)

  • (swc/hygiene) Prefer not renaming top level variables (#2940) (beb2c73)

  • (webpack/ast) Remove more string literals (#2957) (1eb62dc)

  • (webpack/ast) Fix amd support (#2959) (eda514b)

  • (webpack/ast) Preserve more arguments of define calls (#2960) (4008a65)

  • (webpack/ast) Reduce if statements (#2969) (2a01dd4)

  • (webpack/ast) Preserve span (#2971) (74363e0)- general: (es/compat): Change order of passes (#2949) (99da422)

Miscellaneous Tasks

  • general: Add a script to manage crates (b9baa50)- general: Make rust-analyzer faster (#2962) (02322aa)- general: Remove duplicate version field in package.json (#2965) (ce60138)- general: Inline @swc/helpers (#2972) (ffec782)

Performance

  • (es/compat) Migrate class_properties to VisitMut partially (#2966) (89af8ab)

Refactor

  • (es/compat) Migrate destructuring to VisitMut (#2947) (084eebe)

  • (es/parser) Remove import_assertions from TsConfig (#2950) (97df4ce)

  • (es/preset-env) Avoid unnecessary unwrap (#2943) (3302d17)

Build

  • general: Update .npmignore (#2963) (ad35d95)

[1.2.117] - 2021-12-02

Bug Fixes

  • (ci) Fix freebsd builds (#2944) (a93f111)

Features

  • (es/transforms/compat) Add loose mode to parameters (#2911) (1555ceb)

Miscellaneous Tasks

  • general: Break cycles (#2941) (0304c55)- general: Drop freebsd for publishing (82c8694)

[1.2.116] - 2021-12-01

Bug Fixes

  • (bundler) Use interop for common js dependencies (#2930) (24de550)

  • (css/ast) Fix type definition of @namespace (#2919) (0f4ad0f)

  • (css/ast) Fix type definitions related to parsing unknown at-rules (#2922) (8781527)

  • (webpack/ast) Fix span of null literals (#2925) (18d9fd9)

  • (webpack/ast) Fix handling of define (#2935) (9f5fc11)

  • (webpack/ast) Fix ast reducer (#2936) (667dd1e)

  • (webpack/ast) Don't remove comparison of process.env.NODE_ENV (#2937) (4539b3a)

Features

  • (es/preset-env) Upgrade browserslist-rs (#2927) (8a55870)

[1.2.115] - 2021-12-01

Bug Fixes

  • (es/transforms/compat) Fix block scoping (#2916) (028d0ce)

  • (es/transforms/compat) Fix destructuring (#2904) (0c1f2eb)

  • (webpack/ast) Fix ast reducer (#2914) (32b68ef)

  • (webpack/ast) Improve ast reducer (#2917) (854b598)

Features

  • (css/ast) Add a flag to number types (#2905) (fcd0d7a)

  • (plugin/runner) Supports specifying exact path for plugin (#2918) (5999634)

Miscellaneous Tasks

  • general: Reduce compile time (158d4bc)

Performance

  • (es/transform/compat) Migrate optional_chaining to VisitMut (#2891) (4075ff8)

[1.2.114] - 2021-11-29

Bug Fixes

  • (css) Handle custom properties properly (#2869) (c94735e)

  • (es/parser) Fix parser (#2903) (c186aa4)

  • (es/preset-env) Enable "mobile to desktop" (#2907) (5a68a36)

  • (es/transforms/module) Fix overriding of export * (#2883) (6f05c10)

  • (swc) Unimplement Default for JsMinifyOptions (#2901) (bb66083)

  • (webpack/ast) Adjust acorn options. (#2908) (586ab0c)

Features

  • (css/ast) Add support for nested @at-rules (#2897) (c77ebbe)

  • (css/parser) Add more error recovery (#2849) (d7183d8)

  • (plugin) Rename Plugin to JsPlugin (#2893) (ffcb357)

  • (plugin) Enable plugin support under experimental flag (#2894) (91ef3cc)

  • (swc) Implement Default for JsMinifyOptions (#2899) (5425509)

Miscellaneous Tasks

  • (es/preset-env) Upgrade browserslist-rs (#2889) (af216c1)- general: Reduce compile time (#2909) (435facc)- general: Fix cargo config (3695159)- general: Fix cargo config again (189a590)- general: Revert (166c12d)- general: Revert #2907 (666e3cc)

[1.2.113] - 2021-11-27

Bug Fixes

  • (css/ast) Fix AST definitions for @keyframes (#2848) (ce6c7ee)

  • (css/parser) Fix span of type selectors (#2870) (c40e134)

  • (es/transforms/compat) Fix destructuring (#2866) (a6398e9)

  • (es/transforms/compat) Fix arrow (#2882) (803787a)

  • (es/transforms/module) Fix detection of helpers to inject (#2868) (43e89fd)

  • (node) Fix parseFile (#2881) (7bccbcc)

  • (swc) Fix handling of jest option (#2892) (ddc3aca)

Features

  • (css/minifier) Initialize crate (#2884) (c6cb790)

  • (es/estree) Allow emitting acorn ast (#2859) (cdef843)

  • (es/parser) Implement more error recovery (#2874) (b853d4a)

  • (webpack) Add ast reducer (#2875) (c2bbdbe)

Miscellaneous Tasks

  • general: Allow using #[doc(cfg)] (#2871) (28850ee)- general: Document features (#2890) (f5af22e)

Performance

  • (es/transforms/compat) Migrate spread to VisitMut (#2888) (283074c)

Refactor

  • (css/lexer) Follow spec more closely (#2839) (4bf1f93)

  • (es/transforms/compat) Improve async_to_generator (#2876) (a350d86)

[1.2.112] - 2021-11-24

Bug Fixes

  • (bundler) Ignore require of external modules (#2840) (c8de935)

  • (es/lexer) Fix lexing of hexadecimal escape sequences (#2838) (cf777c5)

  • (es/minifier) Fix bugs (#2779) (fa342a0)

  • (es/parser) Fix span of named export (#2813) (338b8fd)

  • (es/parser) Fix span of empty modules (#2827) (9525ea1)

  • (es/parser) Fix comments of empty modules (#2828) (79ba13c)

  • (es/transforms/base) Fix ts_resolver (#2824) (9cd3d16)

  • (es/transforms/base) Fix ts_resolver (#2826) (7a6bf42)

  • (es/transforms/compat) Reduce .bind(this) (#2806) (26734d4)

  • (es/transforms/compat) Fix this in constructor (#2818) (6a7775b)

  • (es/transforms/typescript) Allow enum aliases when values are strings (#2816) (95a6a28)

  • (graph_analyzer) Allow invoking load multiple time (#2823) (020b4a5)

Features

  • (css/parser) Improve parser api (#2847) (839a99e)

  • (es/minifier) Improve drop_console (#2830) (c5768d7)

  • (es/preset_env) Use browserslist-rs (#2845) (2c099bf)- general: Enable logging of timings (#2833) (6b96a3d)

Miscellaneous Tasks

Performance

  • (es/transforms/compat) Migrate parameters to VisitMut (#2804) (372f5bf)

  • (es/transforms/compat) Migrate block_scoping to VisitMut (#2817) (a9a9833)

  • (es/transforms/compat) Migrate computed_props to VisitMut (#2857) (1609580)

Refactor

  • (css/ast) Split pseudo class and pseudo element (#2675) (4bcf3fc)

  • (es/estree) Rename: babel => estree (#2846) (790a262)

  • (es/transforms/compat) Lift this replacer out of arrow (#2812) (fbcbeb4)

Bench

  • (es/visit) Add some benchmarks (#2820) (d64b066)

[1.2.111] - 2021-11-19

Bug Fixes

  • (css/parser) Fix parsing of whitespaces (#2787) (e32093e)

  • (es/parser) Allow static/declare to be optional class property name (#2782) (1caa61a)

  • (es/transforms/compat) Fix optional_chaining(#2791) (29da148)

  • (es/transforms/compat) Remove .bind(this) (#2776) (5261df5)

  • (es/utils) Fix collect_decls (#2792) (af420ea)

  • (es/utils) Fix extract_var_ids (#2798) (02ffe8a)

  • (wasm) Fix wasm-web (#2803) (1368981)

Refactor

  • (css/ast) Rename StyleRule to QualifiedRule (#2756) (c50cec1)

[1.2.110] - 2021-11-17

Bug Fixes

  • (es/transforms/compat) Revert #2740 (#2784) (06e02d8)

Miscellaneous Tasks

  • (es/minifier) Add a script to copy tests from a next.js app (#2778) (e1b7665)

[1.2.109] - 2021-11-17

Bug Fixes

  • (es/lexer) Fix handling of jsx escapes (#2723) (11d1fa5)

  • (es/loader) Add more built-in modules (#2760) (fdd6eaa)

  • (es/minifier) Don't inline string literals if it's used multiple time (#2748) (f2c67b8)

  • (es/parser) Check for more typescript class names (#2732) (6e10168)

  • (es/transform/compat) Preserve more span (#2766) (ddfc7e6)

  • (es/transforms/compat) Fix new_target (#2736) (571c5e3)

  • (es/transforms/compat) Apply block_scoping before regenerator (#2740) (bb646cc)

  • (es/transforms/compat) Preserve more span (#2762) (2fb4e5a)- general: Revert #2766 (#2774) (95e7f4d)

Features

  • (css/ast) Add types for An+b syntax (#2759) (6ce437d)

  • (es/transforms/compat) Add more loose mode (#2611) (dc58122)

  • (swc) Add IsModule (#2601) (65d376a)

Miscellaneous Tasks

  • general: Fix broken link (#2737) (79fc464)- general: Update markdown files to use "SWC" instead of "swc" (#2744) (3ebc5c6)- general: Change Gitter link to Discord (#2752) (015b258)- general: Rename the default branch from master to main (#2750) (6b70fb5)- general: Ensure feature.manyFiles of Git is enabled (#2754) (8aea5eb)- general: Fix benchmark github action (#2755) (54bc405)- general: Fix typo (#2764) (2e01876)- general: Fix links and paths (#2773) (58bf5a5)

Refactor

  • (css/ast) Rename Text to Ident (#2726) (65ee1b4)

  • (es/parser) Simplify skip_line_comment (#2768) (1bb2c68)

  • (es/transforms/compat) Migrate to VisitMut (#2709) (6148d0c)

  • (es/transforms/compat) Migrate to VisitMut (#2751) (e7cbe3d)

  • (swc_bundler) Extract logic for analyzing cycles (#2733) (b869c81)- general: Flatten css (#2731) (1d518fe)- general: Cleanup (#2749) (2462b99)

Testing

  • (swc) Add a test for sourcemap (#2777) (53c8939)

[1.2.108] - 2021-11-11

Bug Fixes

  • (css/lexer) Exclude whitespace from spans (#2702) (0b10423)

  • (css/parse) Fix parsing of pseudo elements and pseudo classes (#2672) (465c188)

  • (css/parser) Fix parsing of escaped characters (#2700) (d8ddb2f)

  • (es) Fix paths support (#2712) (1d028fe)

  • (es) Move TargetEnv to loader from ast (#2719) (665c8e0)

  • (es/minifier) Fix minifier (#2711) (df635c9)

  • (es/transforms/async_to_generator) Fix handling of this (#2667) (01727c0)

  • (es/transforms/common_js) Allow reassignment to functions exported as default (#2705) (691e5e5)

  • (es/transforms/compat) Apply regenerator for default function declarations (#2681) (8fe0d25)

  • (es/transforms/compat) Use _createSuper for super classes (#2699) (8edd72e)

  • (es/transforms/react) Fix handling of whitespaces (#2638) (7ab3b5b)

  • (swc) Don't print same error twice (#2692) (22ce68c)

  • (swc) Fix tests (#2707) (a90fae5)

Features

  • (rplugin) Implement general AST processing plugin system (#2671) (bf0007b)

Miscellaneous Tasks

  • general: Update rustc to prevent CVE-2021-42574 (#2690) (368b9e2)- general: Update README.md (#2693) (cb68956)

Performance

  • (es/transforms/compat) Migrate to VisitMut (#2696) (824fa24)

Refactor

  • (css/ast) Refactor complex selector to represent all css (#2660) (75e6e08)

  • (css/ast) Remove UniversalSelector (#2673) (4484d64)

  • (es/transforms/bugfix) Migrate edge_default_param to VisitMut (#2676) (8915913)- general: Remove trailing whitespace (#2668) (94cb430)- general: Flatten crates (#2697) (687305f)- general: Flatten more packages (#2706) (4f70ee6)- general: Flatten ecmascript (#2708) (2b2f695)

Testing

  • (css/codegen) Add tests for parenthesis (#2691) (9824fda)

  • (css/parser) Add a test for BOM (#2686) (ca2338e)

[1.2.107] - 2021-11-06

Bug Fixes

  • (css/lexer) Fix some edge cases (#2612) (c89a9ea)

  • (css/parser) Exclude whitespace from span (#2659) (a8e4c72)

  • (es/compat) Fix order of transforms (#2629) (550584f)

  • (es/minifier) Fix minifier (#2597) (306cf98)

  • (es/minifier) Fix bugs of the minifier (#2610) (9cb3bf9)

  • (es/minifier) Fix for react-countup (#2625) (7ea4ee8)

  • (es/minifier) Fix for @emotion/react and murmur2 (#2637) (808d578)

  • (es/transforms) Fix detection of this (#2634) (f4efd7a)

  • (es/transforms/cjs) Allow mixing named exports and export stars. (#2583) (7e3fb0a)

  • (es/transforms/cjs) Allow using multiple export * (#2598) (5b141ee)

  • (es/transforms/compat) Fix static blocks (#2652) (d1523dc)

  • (es/transforms/strip) Strip types for typescript export equals (#2623) (d2f2409)

  • (es/transforms/typescript) Allow (foo as any) = bar (#2631) (12be4b1)

  • (node/types) Add es6 to ModuleConfig (#2648) (b6a5656)

  • (plugin) Fix serialization and deserialization (#2651) (a683636)

Features

  • (css/ast) Add RoundBracketBlock to Value (#2618) (8c61d0d)

  • (css/ast) Add SelectorList (#2639) (0b76d29)

  • (css/ast) Add nested selector (#2641) (6ae3af3)

  • (es/ast) Implement Take for more types (#2649) (0414c31)

  • (es/ast) Add utils (#2657) (994c965)

  • (plugin) Proxy swc_common apis (#2646) (3807229)

  • (swc) Provide &Program to pass creator (#2665) (3dc1e76)

  • (swc_common) Allow dylib (#2628) (04238d0)

Miscellaneous Tasks

  • general: Use form for issues (#2595) (a278eff)- general: Fix syntax of github issue template (#2596) (c05f35d)- general: Update playground link in the issue form (#2621) (f8c7d36)- general: Improve version manager script (3935400)

Refactor

  • (css/ast) Use names from specification for ast types (#2643) (20f4e21)

  • (css/ast) Rename NamespacedName to TypeSelector (#2642) (c361982)

  • (css/lexer) Refactor lexer to follow spec (#2593) (b806551)

  • (css/parser) Refactor parser for at rules (#2617) (cc5398b)

  • (es/parser) Deprecate JscTarget (#2600) (3280b4c)- general: Move HANDLER to swc_common (#2599) (e589d00)

[1.2.106] - 2021-10-31

Bug Fixes

  • (css/parser) Resolve some TODOs (#2572) (47f7f1a)

  • (es/lexer) Fix parsing of interpreter (#2589) (52318a4)

  • (es/minifier) Fix minifier (#2564) (4b2903e)

  • (es/minifier) Fix block unwrapping issue (#2570) (69cfa98)

  • (es/transform/react) Allow multiple JSX pragmas in single Comment (#2561) (3f5c826)

  • (es/transforms/cjs) Allow reassignment to exported functions (#2569) (7cc51be)

  • (swc) Use standard base64 charset for inlined source maps (#2585) (4327d11)

Features

  • (css/ast) Add value to the whitespace token (#2533) (4f04736)

  • (css/ast) Add SquareBracketBlock (#2573) (f77d6ce)

  • (css/parser) Use Function token. (#2571) (67c0d4c)

  • (es/transforms/regenerator) Allow configuring import path (#2581) (33bc3d2)

  • (es/transforms/testing) Reduce CI time by caching execution result (#2565) (0364f9a)

Miscellaneous Tasks

  • (ci) Don't use push action (b197eb6)- general: Fix failing tests and improve CI scripts (#2563) (7e29685)- general: Fix CI script for PRs (#2575) (a6af0ab)- general: Make cargo test --all work (#2580) (f9a8ad3)- general: Fix typo (#2586) (ef3c9a7)- general: Manage crate version using github action (#2587) (f997bc4)- general: Fix script for managing crates (#2588) (d63553e)- general: Fix crate manager script (bab638c)- general: Fix permission issue (ceb025b)- general: Fix musl target (dfd8d1a)- general: Use ubuntu-18.04 for musl (e3b8e53)

Performance

  • (node/swc) Parse input using worker thread (#2590) (db09bce)

Ci

  • general: Sync to latest napi workflow (#2592) (1a659d3)

[1.2.105] - 2021-10-28

Bug Fixes

  • (es/minifier) Don't treat catch clause as a scope (#2557) (79a426e)

Features

  • (css/ast) Add raw to the hash value (#2535) (303cecb)

  • (es/parser) Enable ergonomic brand checks for TypeScript (#2562) (7b4af43)

Miscellaneous Tasks

[1.2.104] - 2021-10-27

Bug Fixes

  • (es/fixer) Preserve more parens (#2553) (97b5a73)

  • (es/minifier) Fix minifier (#2528) (dcf5f05)

  • (es/minifier) Fix minifier (#2551) (f81b60f)

  • (es/transforms/react) Revert #2542 (#2552) (5f0524c)

  • (es/transforms/typescript) Remove declared class properties (#2530) (693181e)

  • (swc) Fix bugs (#2538) (b8933e3)

  • (swc) Allow overriding specified parser config using .swcrc (#2547) (8494f65)

Features

  • (es/transforms/react) Improve development more (#2542) (70f5583)

Miscellaneous Tasks

  • general: Remove useless submodules (#2537) (265084c)- general: Configure kodiak (2febd77)- general: Disable freebsd build to publish (e3869f1)

Performance

  • (es/minifier) Make name mangler parallel (#2527) (a099e8f)

Refactor

  • (css/ast) Rename types (#2532) (0e45877)

  • (css/codegen) Use raw instead (#2534) (5ef6686)

  • (css/parser) Fix parsing of some selectors (#2525) (6876b1b)

Ci

  • general: Limit number of runs in graph (#2540) (edc97ef)

[1.2.103] - 2021-10-25

Bug Fixes

  • (bundler) Fix name of helper (#2518) (5afedf8)

  • (bundler) Fix bundler (#2510) (cead404)

  • (es/minifier) Fix minifier using Deno test suite (#2503) (9e21576)

  • (es/minifier) Improve name mangler (#2509) (fce3b79)

  • (es/transforms/compat) Change error message (#2500) (52dfb55)

  • (es/transforms/compat) Fix async_to_generator (#2526) (e7189fb)

  • (es/transforms/optimization) Fix inline_globals (#2524) (709b3c7)

  • (es/transforms/react) Fix hygiene of react fast refresh (#2501) (175c997)

  • (es/transforms/typescript) Fix strip (#2496) (c29a6e1)

Features

  • (css/ast) Add Percent token (#2482) (e327c9a)

  • (es/babel) Support babelify of static blocks (#2504) (91717c9)

  • (es/transforms) Move class_properties to es2022 (#2512) (ecd617a)

  • (es/transforms) Move stage 4 proposals to es2022 (#2519) (65c83e8)

  • (es/transforms/compat) Add single-property optimization to destructuring (#2511) (f33d321)

  • (es/transforms/module) Fix transform of this for classes (#2514) (c482162)

  • (swc) Add browserslist to optionalDependencies (#2515) (4abde38)

Refactor

  • (css/parser) Respect spec (#2487) (430a06c)

Testing

  • (es/minifier) Add a test for moment.js (#2522) (a8b29b6)

  • (es/transforms/compat) Add tests for optional_catch_binding (#2502) (a9869e6)

Ci

  • general: Re-enable FreeBSD build (#2497) (1b91d55)

[1.2.102] - 2021-10-21

Bug Fixes

  • (css/parser) Fix parsing of url (#2484) (d83bde8)

  • (es) Fix simple bugs (#2495) (eef3d6e)

  • (es/minifier) Fix regexp handling (#2489) (7c5b6ca)

  • (es/minifier) Fix join_vars (#2494) (cef2c86)

  • (es/parser) Fix parsing of a property named async (#2485) (3886eed)

  • (es/transforms/base) Reimplement hygiene (#2408) (26944e1)

Features

  • (css/ast) Add Function token (#2491) (b62dc60)

  • (es/trasform) Support static blocks (#2474) (bb1cc97)

  • (swc) Allow removing filename from error output (#2498) (ecf0d75)

Miscellaneous Tasks

  • (ci) Prevent benchmark from marking PR as failed (#2488) (eef63ca)

[1.2.101] - 2021-10-19

Bug Fixes

  • (css/ast) Use correct type for units (#2464) (5234530)

  • (es/minifier) Fix minifier (#2477) (0020e16)

  • (es/transforms/compat) Fix handling of private static properties (#2478) (9b96885)

  • (swc) Change default value of inlineSourcesContent (#2471) (ee880d6)

Features

  • (es/transforms/optimization) Support inlining of typeofs (#2473) (2ca6e5d)

  • (es/transforms/optimization) Improve inline_globals (#2479) (b0361ca)

Miscellaneous Tasks

  • general: Fix typo (#2472) (123c1f5)

Performance

  • (es/parser) Make typescript parser faster (#2483) (bf886ba)

[1.2.100] - 2021-10-19

Bug Fixes

  • (common) Fix sourcemap (#2457) (9ba68c6)

  • (es) Fix bugs (#2469) (c9437d3)

  • (es/minifier) Check for conditional usages while inlining (#2459) (06ca25f)

  • (es/regenerator) Fix for nested try (#2463) (201c0fc)

  • (es/transforms/compat) Fix regenerator (#2460) (5bcabb0)

Features

  • (swc) Accept map for envs (#2467) (28f2c7a)

Miscellaneous Tasks

  • general: Add include to swc (ac77240)- general: Add CI steps for combined benchmark data (#2458) (8c0c250)

Performance

  • (es/transforms) Improve performance (#2454) (575aa44)

Testing

  • (es) Use typescript test suite as a golden testing (#2456) (675c0e7)

  • (es) Freeze as es2015 to verify base transforms (#2468) (01e171a)

[1.2.99] - 2021-10-17

Bug Fixes

  • (css/parser) Fix parsing of numbers (#2444) (4f2dbd8)

  • (es/codegen) Escape backtick of synthesized template literals (#2453) (de368f6)

  • (es/minifier) Fix minification of react hooks (#2450) (63ad4b4)

Performance

  • (es/transforms) Reduce usage of #[fast_path] (#2442) (1645bb3)

  • (es/transforms) Make transforms parallel (#2449) (3d204b4)

[1.2.98] - 2021-10-16

Bug Fixes

  • (es) Fix bugs (#2447) (ee9177b)

  • (es/transforms/base) Fix resolver (#2448) (7ab07ab)

Features

  • (css) Add BadUrl token (#2426) (c2ce89c)

  • (css/parser) Allow invalid line comments (#2443) (7f04ef4)

[1.2.97] - 2021-10-15

Bug Fixes

  • (css/ast) Fix delimiter token (#2415) (e2e4f2f)

  • (es/codegen) Fix codegen of synthesized template literals. (#2440) (d045244)

  • (es/minifier) Fix bugs (#2433) (0e48284)

  • (es/transforms/proposal) Fix type detection (#2431) (f899584)

Features

  • (es/transforms/module) Add an option to preserve dynamic imports (#2441) (130a47f)

Miscellaneous Tasks

  • (doc) Add an example of stripping out types (#2430) (647d3ed)- general: Check for issues already fixed (#2429) (a25d67b)

Performance

  • (es/codegen, es/parser) Improve performance (#2406) (4c983e9)

  • (es/transforms) Reduce usage of #[fast_path] (#2439) (e722bd4)

Refactor

  • (css/ast) Use delim token (#2425) (93a7a17)

[1.2.96] - 2021-10-14

Bug Fixes

  • (css/parser) Fix parsing of comments (#2414) (f7b065e)

  • (dev/cli) Remove CLI from main swc repositoy (#2393) (897f4b6)

  • (es) Fix bugs (#2403) (6366d05)

  • (es/minifer) Fix handling of callable expressions (#2379) (ab687a0)

  • (es/minifer) Fix bugs (#2397) (98cc79a)

  • (es/minifier) Fix iteration order (#2412) (62f7f65)

  • (es/minifier) Fix infinite loop (#2424) (aff6670)

  • (es/parser) Allow using async as the first one in parameters (#2386) (2379fe1)

  • (es/parser) Allow using async as the first one in parameters (#2388) (be3dca2)

  • (es/parser) Allow async in TsAsExpr (#2395) (4458f9c)

  • (es/parser) Fix async function in SeqExpr (#2399) (d7f570f)

  • (es/parser) Ensure that comments are collected (#2407) (4d47711)

  • (es/parser) Fix class getter/setter ASI bugs (#2409) (9446a03)

  • (es/transforms) Fix for react + typescript (#2422) (76de513)

  • (es/transforms/base) Fix hyigiene (#2421) (8074c72)

  • (es/transforms/react) Fix escape of quote in HTML entities (#2419) (029cf05)

  • (es/transforms/testing) Fix test_fixture (#2400) (f560789)

  • (swc) Fix bugs (#2396) (ff2baf7)

  • (swc) Fix order of passes (#2427) (51d7a14)

Features

  • (css/ast) Add raw to Str (#2295) (a5592e3)

  • (css/ast) Add raw to Url (#2389) (2678c34)

  • (css/ast) Add delim token (#2398) (fb4869f)

  • (plugin/api) Determine plugin api (#2199) (7a31a3f)

Miscellaneous Tasks

  • (plugin) Publish (fd08a27)- general: Fix CI script for publising (5fb5a70)- general: Disable freebsd to publish (267d639)

Performance

  • (atoms) Update string_cache (#2411) (4411d1d)

  • (bundler) Improve performance (#2384) (ac3fbd9)

  • (bundler) Improve performance (#2394) (b5f8321)

  • (es/transforms/base) Make resolver faster (#2392) (a330322)

Refactor

  • (es/parser) Simplify parsing logic (#2405) (4ad25d2)

  • (es/parser) Cleanup codes for the comment buffer (#2410) (d114e7d)

Testing

  • (css/parser) Add tests for comments (#2364) (a36f8e4)

[1.2.95] - 2021-10-09

Bug Fixes

  • (css) Change the type of the source of @import rules. (#2363) (cf1235e)

  • (es/codegen, es/transforms/typescript) Fix bugs (#2383) (2c058cb)

  • (swc) Fix sourceMap option of minify (#2380) (486c689)

Refactor

  • (es/parser) Simplify parsing logic (#2381) (644e49c)

[1.2.94] - 2021-10-08

Bug Fixes

  • (css/parser) Fix parsing of funxtion named url (#2350) (6863d96)

  • (es/minifier) Don't optimize new String. (#2341) (8403057)

  • (es/minifier) Fix inlining into shorthand properties (#2348) (87b20a8)

  • (es/minifier) Fix minifier (#2355) (9e6a1f4)

  • (es/parser) Report errors for multiple array elements without comma (#2366) (521e671)

  • (es/parser) Report errors for array patterns without comma (#2365) (d65ce85)

  • (es/transforms/optimization) Fix dead_branch_remover (#2373) (1f99c3a)

  • (es/transforms/react) Allow non-first jsx directives (#2377) (4466ca6)

  • (es/trasnforms/testing) Improve test_fixture (#2369) (7a19fc6)

  • (es/utils) Fix macros (#2349) (b64afb5)

  • (node/bundler) Prevent spreading string into return (#2335) (f426166)

  • (swc) Fix order of custom passes (#2347) (6d35e7c)

  • (swc) Fix order of custom passes (#2367) (edc4cb4)

  • (swc) Fix swc as a crate (#2376) (656f3e9)

  • (testing) Fix CRLF issue on windows (#2338) (20171a3)

Documentation

  • (es/ast) Document identifier mangagement system (#2371) (b0ee954)

Features

  • (babel/compat) Support type-only import/export specifiers (#2342) (ef4c80b)

  • (css) Add error recovery for tokens in selector positions (#2357) (3714802)

  • (css/ast) Add raw to Text (#2361) (4ff1b75)

  • (es/codegen) Expose more API (#2375) (500dbf2)

  • (swcpack) Enable concurrent mode (#2356) (d0342a5)

Miscellaneous Tasks

  • (ci) Add a CI script to publish from github actions (#2353) (305f90c)

  • (es/minifier) Publish (#2354) (a553451)- general: Improve documentation for rust users (#2340) (bbefa0e)- general: Setup workfllow to bump version (#2368) (e2a0edd)

Performance

  • (es/transforms) Improve performance (#2329) (fac6f47)

Testing

  • (css/parser) Combinators (#2359) (f0be833)

  • (css/parser) Add tests for hex colors (#2360) (1e9ecfb)

[1.2.93] - 2021-10-01

Bug Fixes

  • (css/parser) Fix error recovery logic of property values (#2331) (9f4c5b7)

  • (es) Fix performance bugs (#2313) (6a41e9a)

  • (es/codegen) Fix codegen of numbers (#2317) (bd92d89)

  • (es/minifier) Fix minifier (#2323) (dad7392)

  • (swc) Fix try_with_handler (#2315) (2c50cde)

Features

  • (css/parser) Implement more error recovery (#2316) (ce40ff7)

Miscellaneous Tasks

  • general: Update rustc (#2332) (a7357ab)

Performance

  • (common) Avoid string re-allocation (#2318) (fee270f)

[1.2.92] - 2021-09-28

Bug Fixes

  • (css) Reexport codegen from swc_css (#2314) (36c8312)

  • (es/minifier) Fix bugs (#2283) (e8a1710)

  • (es/parser) Report errors for multiple import/export specifiers without comma (#2302) (83153a0)

  • (es/parser) Improve error message (#2304) (552fc23)- general: Migrate dependencies (#2307) (650e149)

Features

  • (css) Recover from invalid properties (#2312) (b206404)

  • (es) Support type-only import/export specifiers (#2309) (2b292e6)

  • (es/parser, es/transform) Implement ergonomic brand checking (#2079) (e46a842)

  • (node/swc) Add a named export for Visitor (#2291) (2580f1a)

[1.2.91] - 2021-09-24

Bug Fixes

  • (css/ast) Fix typo (#2298) (75c930c)

  • (css/parser) Fix parsing of !important (#2286) (2f4da9a)

  • (es/parser) Fix bugs (#2255) (ca0d6dd)

  • (es/transforms/base) Fix hygiene (#2299) (5e1003e)

  • (swc) Fix simple bugs (#2292) (1b2e670)

Miscellaneous Tasks

  • general: Improve docs (#2301) (83d88ce)

Testing

  • (css/parser) Add tests for @page at-rule (#2296) (2a565e8)

  • (css/parser) Add tests for comments in selectors (#2293) (8af2173)

[1.2.90] - 2021-09-23

Bug Fixes

  • (es/transforms/base) Fix hygiene (#2282) (2156364)

  • (node/swc) Allow JsMinifyOptions type for JscConfig.minify (#2287) (4846c32)

Miscellaneous Tasks

  • general: Ignore linguist detection for fixtures (#2285) (e538970)- general: Fix typo (#2288) (dd3f18b)

[1.2.89] - 2021-09-21

Bug Fixes

  • (css/parser) Allow @at-rules to be lowercased (#2274) (9eb45e8)

  • (css/parser) Fix parsing of url (#2280) (b5ad03d)

  • (es) Fix bugs (#2256) (ce01b8a)

  • (es/codegen) Fix codegen of ` in synthesized template literals (#2260) (e2d8465)

  • (es/codegen) Emit static before readonly (#2271) (8e0a545)

  • (es/minifier) Don't drop used variables (#2272) (3f306f0)

  • (es/transforms/base) Fix hygiene pass (#2266) (180dc31)

  • (es/transforms/compat) Move the optional catch binding pass to ES2019 (#2247) (4d500ba)

  • (es/transforms/testing) Fix comparing logic (#2263) (f087d15)

  • (swc) Remove global side effects for rust users. (#2270) (b82702c)

  • (wasm) Fix bugs (#2279) (e5f46a6)

Features

  • (es/minifier) Add CLI for debugging (#2273) (406fa3f)

Miscellaneous Tasks

  • general: Add discord server link to README.md (#2278) (893fb08)

[1.2.88] - 2021-09-16

Bug Fixes

  • (es/transforms) Fix bugs (#2249) (6f33c32)

Features

  • (es/minifer) Improve minifier (#2229) (20ce326)

Miscellaneous Tasks

  • general: Add a link to github sponers (ff389ca)

[1.2.87] - 2021-09-14

Bug Fixes

  • (ci) Publish (#2250) (cab37f8)

  • (common, node/swc) Allow inlining sourcesContent (#2245) (48d6103)

  • (es/transforms/compat) Add new.target to es5 (#2231) (6e12ef0)

Features

  • (node/swc) Enable tsx automatically based on the extension (#2230) (4ca85ec)

[1.2.86] - 2021-09-11

Bug Fixes

  • (ci) Publish v1.2.86 (#2235) (f78a504)

  • (css/parser) Fix parsing of selectors (#2221) (a9573b9)

  • (es) Fix bugs (#2222) (2c47778)

  • (es/loader) Fix support for jsc.paths. (#2227) (9eafd0c)

  • (swc) Fix target (#2226) (9ffe471)

[1.2.85] - 2021-09-09

Bug Fixes

  • (css/parser) Fix parsing of selectors (#2217) (d8ae4c4)

  • (es/parser) Fix parsing of static blocks (#2200) (cbc8230)

  • (swc) Improve rust apis (#2197) (77be9f6)- general: Fix simple bugs (#2220) (b4796d9)

Features

  • (common) Add variants to FileName (#2202) (87f30b2)

  • (es/minifier) Implement more rules (#2183) (c8b46bf)

[1.2.84] - 2021-09-01

Bug Fixes

  • (es) Fix easy bugs (#2178) (c0b0337)

  • (es/loader) Fix node resolver (#2172) (5d70283)

  • (es/loader) Improve handling of base_dir (#2182) (361bc70)

  • (es/parser) Remove static_blocks from TsConfig (#2186) (2f2e35a)

  • (es/transforms) Fix bugs (#2181) (ee16139)

  • (es/transforms/base) Optimize hygiene (#2193) (cb2b0c6)

Documentation

  • (common) Improve doc of Take (#2192) (55f065b)

Features

  • (common) Implement TypeEq and EqIgnoreSpan for tuples (#2184) (d58642b)

  • (es/minifier) Implement static evaluator (#2176) (11fe35d)

  • (es/parser) Add tests for static blocks (#2180) (b2c9971)

  • (es/parser, es/codegen, es/visit) Support static blocks in classes (#2130) (a10118c)- general: Expose .take() (#2190) (a8cb554)

Refactor

  • (es) Use BlockStmt instead Vec<Stmt> for static blocks. (#2188) (99c35ff)

[1.2.83] - 2021-08-27

Bug Fixes

  • (es) Fix source map (#2159) (d975a19)

  • (es) Fix some easy bugs (#2166) (97514a7)

  • (es/minifier) Fix usage via yarn resolution (#2158) (e468752)

  • (es/transforms/base) Fix await expressions. (#2157) (8c5daee)

Features

  • (plugin) Groundwork for rust plugin system (#1893) (18e2232)

Refactor

  • (es/dep_graph) Use dyn instead of impl (#2119) (3d58457)

[1.2.82] - 2021-08-25

Bug Fixes

  • (es/codegen) Fix sourcemap (#2142) (427df9a)

Features

  • (css/parser) Improve parser api (#2147) (8c57cf0)

  • (es) Reexport minifier from swc_ecmascript (#2146) (584c44a)

Miscellaneous Tasks

  • (es/parser) Update an error message (#2148) (78a7c6b)

[1.2.81] - 2021-08-24

Bug Fixes

  • (bundler) Fix handling of reexports from cjs modules (#2143) (b027824)

  • (css) Fixup (#2138) (81061a9)

  • (es/minifier) Make use of hygiene optimizer (#2145) (838a7a8)

  • (es/transforms/compat) Implement new.tartet (#2129) (c78baef)

Features

  • (bundler) Support replacing any environment variables (#2121) (61e58d7)

  • (css) Groundwork for css processor (#2105) (0d63470)

  • (css) Implement codegen for css (#2115) (7381644)

  • (css) Port stylis (#2131) (c05a724)

  • (es/parser) Report an early error for await used in wrong contexts (#2098) (e3e2908)

Miscellaneous Tasks

  • general: Fix typo in type definition (#2116) (91c239b)- general: Fix typo (#2136) (84cda8a)- general: Fix typo (#2135) (1d71a8e)

[1.2.80] - 2021-08-19

Bug Fixes

  • (swc) Disable aes feature (#2109) (6eaf60b)

[1.2.79] - 2021-08-19

Bug Fixes

  • (es/codegen) Fix codegen of ~ (#2104) (6896a83)

Features

  • (css) Implement parser (#2074) (d39acd1)

  • (es/parser) Emit an error for top-level await in script (#2094) (33bdff0)

  • (swc) Implement format.comments of terser (#2095) (879a0f3)

[1.2.78] - 2021-08-16

Bug Fixes

  • (bundler) Fix stack overflow (#2080) (f8aa050)

  • (es) Fix simple bugs (#2077) (949a4d9)

  • (es/parser) Fix parsing of function in property names (#2076) (b0067ad)

  • (es/parser) Allow using parser with stable rustc (#2084) (1b0ef75)

  • (es/transforms) Fix bugs (#2089) (a309b36)

  • (node/swc) Fix incorrect field package.json (#2069) (035ff77)

Features

  • (es/loader) Support more types for browser in package.json (#2060) (e84ed13)

  • (es/minifier) Implement more rules (#2058) (0e30deb)

Miscellaneous Tasks

  • general: Cleanup codes for fixture testing (#2070) (b0c41bb)

Performance

  • general: Use ahash instead of sip hash (#2073) (f6aabfc)

Testing

  • (es/ext/jest) Add tests for jest (#2082) (ddb2dc7)

[1.2.77] - 2021-08-13

Bug Fixes

  • (bundler) Prepare renaming of bundler (#2066) (883c1ac)

  • (es) Fix bugs (#2055) (72c9f43)

  • (es/minifier) Fix bugs of the minifier (#2052) (a7cb2ab)

  • (swc) Report error correctly (#2065) (c6dce67)

  • (swc) Fix bugs (#2067) (1b9584c)

Features

  • (bundler) Support paths (#2054) (cfc3725)

  • (es/transforms) Improve module transform (#2053) (a26071f)

Performance

  • (node/swc) Use mimalloc (#2068) (fe2a063)

[1.2.76] - 2021-08-10

Bug Fixes

  • (es/parser) Recover from import.meta in scripts (#2042) (8cbbddb)

  • (es/transforms/module) Fix paths bug. (#2043) (2c52021)

  • (swc) Fix bugs (#2034) (53b031b)

Features

  • (es/loader) Support target runtime environment. (#2045) (2151366)

  • (es/minifier) Implement more rules (#2039) (71080db)

Refactor

  • (es/parser) Cleanup (#2033) (4ead801)

[1.2.75] - 2021-08-08

Bug Fixes

  • (es/minifier) Fix bugs and implement more rules (#2032) (9793926)

  • (es/parser) Use correct error message (#2025) (8a39c1d)

  • (es/transforms/classes) Fix a bug related to super property access (#1960) (403f647)

  • (es/transforms/react) Handle escape correctly (#2014) (eb45760)

  • (node/swc) Allow specifying filename when parsing (#2031) (abb1451)

Features

  • (es/minifier) Make minifier parallel (#2009) (026c21e)

  • (es/parser) Always enable features in ES spec (#2029) (f4e0e91)

  • (swc) Improve swc as a crate (#2026) (4cdb45f)

[1.2.74] - 2021-08-04

Bug Fixes

  • (es) Fix codegen & minifier (#2006) (48bc26d)

[1.2.73] - 2021-08-04

Bug Fixes

  • (ci) Fix CI (#2003) (a4fb114)

  • (common) Remove potential race condition (#2001) (080b1fa)

  • (es) Fix bugs (#2004) (81abfe5)

  • (es/minifier) Improve output of minifier (#1990) (f44e25c)

  • (es/minifier) Improve output of minifier (#2005) (68608db)

Features

  • (common) Add an utiliy method for comments (#2002) (064416c)

  • (es/parser) Report an error for import.meta in script (#1999) (a086a20)

[1.2.71] - 2021-08-02

Bug Fixes

  • (es) Ensure that #1681 is fixed (#1970) (6285f20)

Features

  • (node/swc) Support sourceFileName (#1976) (e916b35)

[1.2.70] - 2021-07-31

Bug Fixes

  • (es/minifier) Fix minifier (#1985) (be23e66)

[1.2.69] - 2021-07-31

Bug Fixes

  • (build) Increase memory (d600d52)

[1.2.67] - 2021-07-31

Bug Fixes

  • (es/codegen) Remove extra space of import decl (#1975) (ef4bb31)

  • (es/transforms) Fix passes related to optimizations (#1942) (21848ce)

  • (es/transforms) Fix bugs (#1950) (204a71c)

  • (es/transforms) Strip out private method overloads (#1977) (d64aa6f)

  • (es/transforms/base) Fix hygiene (#1964) (af4cbba)

  • (es/transforms/module) Allow namespace import with default import (#1940) (de24ff2)

  • (es/transforms/typescript) Fix typescript stripper (#1945) (ebdd04d)

  • (node/swc) Fix typings for parser options (#1971) (eecaac1)

  • (testing) Allow using it with stable rustc (#1974) (4011703)- general: Remove println (360b4bc)

Features

  • (es/minifier) Implement more rules (#1871) (b02e189)

  • (es/parser) Allow stripping out typescript parser (#1962) (85a216e)

  • (swc) Expose minifier api (#1978) (d1c4817)

Miscellaneous Tasks

  • general: Fix typo (#1958) (cd4a564)- general: Use correct license for the node package (#1966) (f3603b2)

[1.2.66] - 2021-07-20

Bug Fixes

  • (es/codegen) Fix codegen of template literals (#1936) (39ee7b9)

  • (node/swc) Fix field name (#1923) (d5cdf44)

  • (node/swc) Fix for m1 mac (#1939) (d6454ad)

[1.2.65] - 2021-07-18

Bug Fixes

  • (es/transforms) Allow using rest pattern in arrow functions. (#1926) (a26a189)

  • (swc) Fix order of passes (#1931) (4a9b31d)

  • (swc) Fix bugs (#1932) (ff47e25)

[1.2.64] - 2021-07-14

Bug Fixes

  • (es/parser) Fix parsing of file with onlly shebang (#1896) (ed274b0)

  • (es/transforms) Fix transforms (#1900) (69186eb)

  • (es/transforms) Fix decorator bugs (#1905) (03be315)

  • (es/transforms) Fix transforms (#1909) (104be98)

  • (es/transforms) Fix fixer (#1919) (7a8ad88)

  • (es/transforms/base) Fix ts_resolver (#1903) (fe7f7b6)

  • (es/transforms/compat) Handle nested optional chaining expression (#1899) (6037332)

  • (es/transforms/compat) Fix regenerator (#1906) (480287a)

  • (es/transforms/proposal) Fix order of constructor statements (#1914) (d13eff9)

  • (swc) Fix source path of a source map file (#1902) (19bcb06)

Miscellaneous Tasks

  • (ci) Switch installation method of deno (#1915) (4e42c66)- general: Update README.md (#1910) (8694b11)

Refactor

  • (es/dep-graph) Remove SourceMap dependency (#1908) (6dc6d8a)

[1.2.63] - 2021-07-06

Bug Fixes

  • (bundler) Prevent infinite loop (#1872) (ea93e1d)

  • (ci) Use cross-env (#1897) (04d4384)

  • (es/ast) Fix handling of reserved words (#1891) (7634106)

  • (es/parser) Make comments in empty file be in leading comments (#1879) (534c0b1)

  • (es/parser) Allow using '>' and '<' in template literal types (#1885) (14cee03)

  • (es/transform/react) Handle TypeScript declare module (#1875) (1a01d0f)

  • (es/transforms/module) Fix for duplicate export (#1846) (f8a3df8)

  • (es/transforms/optimization) Migrate to VisitMut (#1880) (ab16179)

  • (node-swc) Fix visitor (#1890) (211e208)

Features

  • (babel/compat) Implement reverse operation of babelify (#1655) (c49e9b0)

  • (es/minifier) Implement more rules (#1766) (33a43f8)

Miscellaneous Tasks

  • (wasm) Fix license (#1874) (c4e0134)

[1.2.62] - 2021-06-27

Bug Fixes

  • (es/codegen) Preserve more comments (#1856) (098e48b)

  • (es/parser) Fix parsing of abstract class over multiple lines (#1837) (6c49279)

  • (es/parser) Fix span of ExportDefaultDeclaration (#1818) (7488950)

  • (es/transforms) Fix transforms (#1861) (33f2ab2)

  • (es/transforms/base) Fix fixer for the call in callee position (#1857) (5345c90)

  • (es/transforms/module) Allow importing same module with multiple names (#1830) (9ae8c47)

  • (es/transforms/module) Share usage data between passes (#1829) (a31ca40)

  • (es/utils) Fix detection of used variables (#1835) (11f75df)

  • (swc) Fix sourcemap (#1832) (5a6c4fd)

Features

  • (ci) Track binary size and performance (#1840) (f424957)

  • (es/loader) Add more logics to tsconfig.paths handler (#1860) (eaaf32d)

  • (es/visit) Groundwork to use VisitMut instead of Fold (#1842) (6ad3f7b)

  • (swc) Add import resolvers (#1834) (4cd4337)

Miscellaneous Tasks

  • (es/ast) Upgrade arbitrary crate to v1 (#1844) (c5f1c6b)

  • (es/ast) Bump version (#1853) (737ce63)- general: Organize project (#1849) (ff440d4)

[1.2.61] - 2021-06-16

Bug Fixes

  • (es) Remove UB (#1815) (3c3fb35)

  • (es) Fix bugs for the type checker (#1823) (7fa4e1b)

  • (es) Improve handling of typescript (#1824) (4c8d68b)

  • (es/parser) Fix parser (#1808) (c561157)

  • (es/parser) Fix lexing of numbers (#1821) (001af86)

  • (es/parser) Fix parsing of line terminators (#1755) (8d8b2d1)

  • (es/parser) Fix panic on debug mode (#1828) (f9bdc7b)

  • (es/transforms/optimization) Fix dead_branch_remover (#1827) (b5a7a3f)

  • (swc) Fix bugs (#1811) (97ef7c0)

  • (swc) Fix bugs (#1820) (d3944f5)

Build

  • (node-swc) Support lower version glibc linux on non-x64 arch (#1809) (c6ce8c6)

[1.2.60] - 2021-06-06

Bug Fixes

  • (bundler) Fix cycle detection (#1779) (4e7723a)

  • (es/transforms) Fix bugs (#1769) (ad55711)

  • (es/transforms) Fix bugs (#1783) (0bd2a3a)

  • (es/transforms) Fix bugs (#1795) (7730a6e)

  • (es/transforms/base) Wrap binary operands of unary expressions. (#1793) (03db7ad)

Features

  • (node-swc) Support windows aarch64 and linux aarch64 musl (#1773) (d657193)

[1.2.59] - 2021-05-30

Bug Fixes

  • (common) Fix compiler error (#1747) (7b9b9fe)

  • (es) Fix bugs (#1728) (a518c83)

  • (es/codegen) Fix codegen of classes with minify enabled (#1767) (5d219b8)

  • (es/parser) Report error for wrong declare keywords (#1760) (65ffd87)

  • (es/transforms/base) Fix ts_resolver (#1761) (9fa878c)

  • (spack) Fix node resolver (#1748) (1150fbc)

  • (spack) Update the list of node js core modules (#1749) (3359188)

  • (swc) Fix bugs (#1732) (a795de7)

  • (swc) Fix bugs (#1739) (d60c324)

  • (swc) Fix bugs (#1745) (8726c9c)

  • (swc) Fix bugs (#1753) (c79db25)

Features

  • (es/minifier) Implement more rules (#1717) (d20c1d3)

  • (es/minifier) Implement more rules (#1730) (3522fc7)

  • (es/minifier) Implement more rules (#1731) (5e2db21)

  • (es/minifier) Implement more rules (#1735) (ef6a745)

  • (es/minifier) Implement rules and classify tests (#1750) (99e7386)

  • (node-swc) Support FreeBSD (#1758) (6a13615)

[1.2.58] - 2021-05-21

Bug Fixes

  • (es) Fix various bugs (#1680) (24bd5ea)

  • (es) Fix various bugs (#1707) (57d1aaf)

  • (es) Fix bugs (#1709) (dee8290)

  • (es/minifier) Use log instead of stderr (#1715) (ded8f2b)

  • (es/minifier) Publish (#1716) (470c8f4)

  • (es/preset-env) Update core js compat data (#1719) (8a2909b)

  • (es/transform) Fix bugs (#1699) (b4aa1d4)

  • (es/transforms) Fix bugs (#1691) (f0d7a3d)

  • (es/transforms/base) Fix resolver (#1710) (a0241c8)

  • (es/transforms/compat) Support private methods (#1700) (b044d2c)

  • (es/transforms/compat) Fix async_to_generator pass. (#1724) (a1341dc)

  • (es/transforsm/compat) Transform private field access in private methods (#1703) (8a36435)

  • (node-swc) Fix typescript definitions for react options (#1720) (c2bd319)

  • (swc) Fix bugs (#1712) (b6589af)

Features

  • (es) Support type-only import equals declaration (#1695) (1dbc364)

  • (es/minifier) Implement minifier partially (#1302) (c6b22c5)

[1.2.57] - 2021-05-11

Bug Fixes

  • (ci) Don't run tests on macos (#1659) (4d013d9)

  • (es) Fix various bugs. (#1664) (b0b0709)

  • (es/parser) Allow using override with static (#1663) (4aed942)

  • (es/tranforms/base) Resolver: Handle function declarations in ts modules (#1665) (aea08fb)

  • (es/transforms/base) Fix resolver (#1666) (9585500)

  • (es/transforms/base) Fix resolver (#1672) (9381d0d)

  • (es/transforms/compat) Fix span for comments in classes transform. (#1658) (c3bf517)

  • (es/transforms/compat) Don't create unnecessary IIFE. (#1669) (2b918b0)

  • (es/transforms/compat) Improve performance (#1673) (2ad0af9)

  • (node-swc) Fixed parseFile (#1654) (0cdabeb)

Features

  • (es/parser) Allow override in parameter properties (#1667) (1548f6d)

  • (es/parser) Enforce order of abstract and override (#1668) (50f8048)

  • (es/parser) Enforce orders of override and async (#1670) (b713972)

  • (es/transforms/compat) Add pure comment to classes (#1646) (f4d0e46)

[1.2.56] - 2021-05-08

Bug Fixes

  • (ci) Fix android build (e3bdb97)

  • (es/transforms/react) Bump version (f368c5f)

[1.2.55] - 2021-05-07

Bug Fixes

  • (bundler) Improve performance (#1599) (9a07869)

  • (bundler) Fix performance (#1601) (308792d)

  • (bundler) Use proper algorithm for dependency analysis (#1610) (731dc68)

  • (ci) Use ghcr.io build image (#1622) (7ea8760)

  • (es/transforms/compat) Allow keywords in method names. (#1651) (1b1c46b)

  • (es/transforms/fixer) Handle binary expressions in super class expr (#1636) (27a1c30)

  • (es/transforms/optimization) Preserve x instanceof Object (#1630) (b6ff4d6)

  • (es/transforms/react) Expose RefreshOptions (#1635) (2724cef)

  • (es/transforms/react) Change order of passes (#1639) (fe107a1)

  • (es/transforms/resolver) Fix setter properties (#1645) (deec1f6)

  • (es/transforms/resolver) Fix setter properties (#1647) (abc24c9)

  • (node-swc) Fix definition of FunctionDeclaration (#1602) (1c1de63)

  • (node-swc) Fix outdated types (#1621) (e9d58fa)

  • (node-swc) Fix definition of JSXOpeningElement (#1608) (304b57c)

  • (swc) Fix bugs (#1591) (dbec753)

  • (swc) Fix various bugs (#1613) (5a0bacb)

  • (swc) Fix bugs (#1624) (28bb61f)

  • (swc) Fix various bugs. (#1632) (d10671b)

  • (wasm-web) Use jq with an explicit temp file (#1637) (882e2d9)

Features

  • (ast_node) Add #[ast_serde] (#1595) (8222cc0)

  • (babel/compat) Improve performance of babelify (#1626) (82ef06a)

  • (es/preset-env) Make android targets fall back to chrome (#1597) (a24266d)

  • (es/transforms/optimization) Simplify: Preserve do-while loops with conditional stoppers (#1618) (f943021)

  • (node-swc) Babel ast translator (#1465) (d1415f9)

[1.2.54] - 2021-04-19

Bug Fixes

  • (es/transforms/compat) Fix syntax context of super classes (#1586) (d7ea5ae)

  • (es/transforms/compat) Handle references to arguments inside arrow functions and block scoped loops (#1585) (1c4fa63)

  • (swc) Fix bugs (#1560) (46c3d62)

  • (swc) Fix various bugs (#1588) (4db24fb)- general: Fix bugs (#1590) (c765c7e)

[1.2.53] - 2021-04-16

Bug Fixes

  • (bundler) Fix bugs (#1572) (246bdd5)

  • (bundler) Fix bundler (#1576) (1178686)

  • (es/transforms/base) Fix nested function scopes (#1559) (92bbde3)

  • (es/transforms/base) Fix precedence of yield expression inside ternary (#1577) (00461f3)

  • (es/transforms/base/fixer) Fix parens of sequence expressions (#1566) (14edb69)

  • (es/transforms/compat) Fix block scoping of class declarations (#1569) (d8a18df)

  • (es/transforms/compat) Fix regenerator pass for yield* expressions (#1580) (efa7a9a)

  • (es/transforms/module) Use correct this (#1561) (df2a926)

  • (es/transforms/optimization) Preserve missing object members (#1567) (e43de77)

[1.2.52] - 2021-04-11

Bug Fixes

  • (es) Fix for the type checker (#1528) (4ab7a91)

  • (es) Fix sourcemap (#1548) (62d0cbc)

  • (es) Fix bugs. (#1565) (5ef3c43)

  • (es/ast) Remove TsSignatureDecl (#1531) (f179270)

  • (es/codegen) Fix sourcemaps of multi line block comments (#1511) (393808a)

  • (es/parser) Fix assert after imports (#1513) (3ddf229)

  • (es/parser) Use correct position for comments (#1527) (5ce4e1e)

  • (es/parser) Disallow override in non-subclass (#1552) (39e1e54)

  • (es/parser) Fix error message (#1551) (f002b73)

  • (es/transforms/base) Fix named function expression handling in resolver (#1540) (beeb1f9)

  • (es/transforms/optimization) Fix inlining nested block statements in branch simplifier (#1536) (0d79ca6)

  • (es/transforms/optimization) Fix function hoisting with early return branch simplification (#1539) (ee641ba)

  • (es/transforms/typescript) Fix TS import elision with shadowed declarations (#1521) (b9f5a50)

  • (node-swc) Make Argument.spread optional (#1535) (dcaea5f)

  • (node-swc) Fix VariableDeclarationKind typescript definition (#1542) (c7dc911)

  • (node-swc) Fix handling of tagged template expressions in Visitor (#1544) (228429c)

  • (strip) Expand class expressions as sequences (8b1f8dd)

  • (swc) Fix bugs for v1.2.52 (#1506) (99f4f0f)

  • (swc) Fix bugs (#1529) (252804d)

  • (swc) Fix various bugs (#1550) (2211a99)- general: Fix bugs (#1516) (51d0cef)

Features

  • (es) Support TS 4.3 static index signature in class (#1537) (6512216)

  • (es) Support override syntax in class for TS 4.3 (#1541) (3d0ad22)

  • (es/transforms/react) Support fast refresh (#1524) (0fabc2c)

  • (es/transforms/react) Fast refresh config (#1538) (6cad184)

  • (es/transforms/react) Add pure annotation comments (#1564) (8f5daa3)

Miscellaneous Tasks

  • (ci) Configure github actions for rustdoc (#1523) (13a9d12)

[1.2.51] - 2021-03-28

Bug Fixes

  • (bundler) Fix stack overflow on Windows (#1464) (fec189f)

  • (bundler) Fix inlining pass (#1495) (7853b0a)

  • (ci) Speed up (#1494) (0351a47)

  • (common) Fix column positions in generated sourcemaps (#1470) (9d53a70)

  • (es/codegen) Fix SX spread props (#1463) (06cb4b8)

  • (es/codegen) Fix codegen of arrow expressions. (#1452) (9445c10)

  • (es/transforms/base) Fix fixer (#1496) (b7eb1f9)

  • (es/transforms/fixer) Fix await expressions. (#1475) (df3f310)

  • (es/transforms/react) Handle jsx entities in attributes correctly (#1501) (232cfc5)

  • (es/transforms/typescript) Precompute class field keys (#1498) (8eae009)

  • (strip) Combine typescript_class_properties() into strip() (#1478) (9bc074e)

  • (strip) Transform static class fields to assignments (#1487) (fa3d65c)

  • (swc) Fix bugs (#1453) (dcdac2d)

Miscellaneous Tasks

  • general: Add note about required dev tools (#1467) (a903683)

Refactor

  • (es/ast) Change TaggedTpl to have a Tpl (#1114) (da62c73)

[1.2.50] - 2021-03-03

Bug Fixes

  • (bundler) Fix bundler (#1427) (c047e0e)

  • (bundler) Fix bugs (#1437) (bbaf619)

  • (es/parser) Recover from type annotations after = (#1445) (73b8826)

  • (es/parser) Fix lexing of template literals. (#1450) (bc07215)

  • (es/transforms/base) Fix span hygiene of type elements (#1436) (a4d408d)

  • (swc) Fix various bugs (#1440) (a310542)

  • (swc) Fix bugs for v1.2.50 (#1444) (97269a3)

Features

  • (es/transforms) Port @babel/preset-modules (#1439) (eec65f2)

Miscellaneous Tasks

  • general: Typo (#1442) (24dac86)- general: Fix link (#1443) (7d62fdf)

[1.2.49] - 2021-02-23

Bug Fixes

  • (common) Allow using with MIRI (#1426) (abfff69)

  • (node-swc) Fix glibc compatibility issue (#1431) (6ece763)- general: Fix tests on windows (#1419) (59bd00d)

[1.2.48] - 2021-02-22

Bug Fixes

  • (bundler) Fix bugs (#1373) (bfde9a1)

  • (bundler) Fix bugs (#1382) (7f5bfdc)

  • (es) Fix for the type checker (#1381) (686c981)

  • (es) Fix bugs (#1395) (9dabf00)

  • (es) Fix docs.rs (#1399) (fc2a8cb)

  • (es) Improve performance (#1411) (eaeffab)

  • (es/ast) Remove TsTypeCastExpr it's not used (#1420) (adcca03)

  • (es/parser) Fix bugs (#1405) (5ad57b0)

  • (es/transforms/base) Fix hygiene of catch clause (#1413) (27aad87)

  • (es/transforms/base) Fix resolver (#1414) (eecdca4)

  • (es/transforms/react) Use VisitMut instead of Fold (#1409) (8fb0b4c)

  • (node) Add es2020 to JscTarget in types.ts (#1376) (98ae167)

  • (node-swc) Don't remove plugin from options (#1390) (a0898e8)

  • (node-swc) Handle empty object patterns. (#1393) (f5a90ae)

  • (swc) Fix bugs (#1372) (bf445a7)

  • (swc) Reduce allocation (#1401) (a53186c)

Documentation

  • general: Fixed documentation link URL in README.md (#1375) (7a93594)

Features

  • (es/parser) Allow to look at the kind of an error (#1396) (313f51f)

  • (es/preset-env) Custom config path (#1374) (bd119e6)

  • (es/transforms/react) New jsx transform (#1408) (0be20ff)

  • (node-swc) Reduce binary size (#1418) (9d896c7)- general: Add import assertion to dep analyzer (#1387) (8ef78a9)

Miscellaneous Tasks

  • (node-swc) Use latest napi versions (#1386) (79e991b)

[1.2.47] - 2021-01-30

Bug Fixes

  • (bundler) Fix bugs (#1349) (947161b)

  • (bundler) Fix pass ordering (#1363) (767f21e)

  • (bundler) Prevent hanging (#1369) (0d130f8)

  • (es) Fixes for type checker (#1359) (93a1914)

  • (es/ast) Compilation (#1357) (2921b90)

  • (es/ast) Fix EqIgnoreSpan (#1360) (947f9c5)

  • (swc) Fix bugs for v1.2.47 (#1368) (af25a88)

Features

  • (es/transforms/typescript) Strip out type-only namespaces (#1361) (78e79a7)

  • (node-swc) Support windows ia32 arch (#1367) (ca417e9)

[1.2.46] - 2021-01-24

Bug Fixes

  • (bundler) Publish (ebc0d0a)

  • (bundler) Fix bugs (#1342) (17f17e8)

  • (bundler) Fix bugs (#1346) (6a1c3da)

  • (es) Fixes for the type checker (#1331) (613a5a4)

  • (es) Move and rename JscTarget (#1343) (0469e3a)

  • (es) Fix bugs (#1347) (d4df2ce)

  • (es) Fix bugs (#1353) (b7ae896)

  • (es/transforms) Handle enum in namespaces (#1340) (ddc9492)

  • (swc) Fix bugs (#1300) (a9bf9bb)

Features

  • (ES/transform/typescript) Support namespace (#1325) (6984217)

  • (es) TypeScript 4.2 (#1330) (3faefb5)

V1.2.46

  • general: Prevent regression. (#1356) (5c3a0b5)

[1.2.44] - 2021-01-11

Bug Fixes

  • (bundler) Fix bundler (#1318) (23aebac)

  • (ci) Insert *_bg files in @swc/wasm-web (#1305) (895b431)

  • (ecmascript/transforms) Fix dce (#1301) (842b6f9)

Features

  • (ecmascript) Remove macros (#1319) (c83d19e)

  • (ecmascript/transforms) Split into multiple crates. (#1311) (76d9e2a)

Miscellaneous Tasks

  • general: Fix website docs link (#1317) (5d88e8b)- general: Update actions/setup-node (#1315) (78dc61a)

[1.2.43] - 2020-12-30

[1.2.42] - 2020-12-29

Bug Fixes

  • (bundler) Fix statement ordering issue (#1264) (b66ee58)

  • (bundler) Fix remaining bugs (#1296) (ba13db5)

  • (bundler) Don't load dynamic imports (#1297) (bc7ac45)

  • (ci) Insert *_bg files in @swc/wasm-web (#1291) (#1293) (066bb4e)

  • (swc) Fixes for typescript type checker (#1146) (6941f29)

Features

  • (ecmascript/ast) Add EqIgnoreSpan and TypeEq (#1295) (34249bb)

  • (ecmascript/codegen) Fix and use omit_trailing_semi (#1298) (9063908)

[1.2.41] - 2020-12-23

Bug Fixes

  • (ci) Fix ci (OOM & library api change) (#1284) (0ead8dc)

  • (ci) Publish npm packages as public (#1277) (#1290) (dd977ff)

  • (ecmascript) Fix bugs related to string literals (#1287) (8a8db58)

  • (ecmascript/codegen) TsQualifiedName has trailing dot (#1268) (b760c7c)

  • (ecmascript/lexer) Normalize \r\n and \r to \n in template literals (#1286) (576fb6a)

  • (ecmascript/parser) Fix span of declare decls. (#1282) (bf69b47)

Features

  • (ecmascript/parser) Add tests for binding patterns (#1289) (c2a9994)

  • (fixer) Handle ?? properly (#1270) (ccf4c2b)

  • (node-swc) Remove duplicate type and correct name (#1267) (261e2ec)

  • (parser) Don't hang on unexpected inputs (#1274) (25856f2)

  • (visit) Add support for Arc (#1256) (718f478)

  • (wasm-web) Initialize (edf74fc)- general: Specifier position in DependencyDescriptor (#1260) (8ba2ae9)

[1.2.40] - 2020-12-03

Bug Fixes

  • (regenerator) Handle ternary correctly (#1228) (f8a1fb8)

  • (source map) Fix inline source map comment slicing (#1237) (cdaefcc)- general: Decorator metadata (#1248) (2e29d78)

Features

  • (swc_common) Expose non-tty EmitterWriter (#1240) (46b553e)

[1.2.39] - 2020-11-22

Bug Fixes

  • (typo) Dowloads => downloads (#1222) (723970d)- general: Publish script (1268206)

Features

  • general: Macro for fixture testing (#1226) (ad23a58)

Bundler

  • general: Fix issues (#1212) (4294b5e)

[1.2.38] - 2020-11-08

Bug Fixes

  • general: SourceMap::span_to_lines for empty file (#1198) (546a01c)

Bundler

  • general: Improve hook for import.meta (#1195) (3cdb62b)- general: Use a local variable for import.meta (#1201) (64942b5)- general: Handle swc helpers (#1199) (0a5e23f)

Resolver

  • general: Handle class declarations (#1200) (f21a288)

[1.2.37] - 2020-10-29

Ast

  • general: Add support for fuzzing (#1167) (11d137a)

Bundler

  • general: Allow importing and exporting from same module (#1152) (f0ea70c)- general: Fix bugs (#1154) (6f00620)- general: Fix dead code elimination (#1157) (5a91ab9)- general: Handle computed accesses correctly (#1159) (ad7cb65)- general: Make output deterministic (#1166) (41d1738)- general: Fix ordering (#1171) (626c881)

Codegen

  • general: Preserve space for postfix unary operators (#1185) (6e9d06e)

Parser

  • general: Remove unnecessary question mark (#1174) (fd760fb)

Transforms

  • general: Fix _typeof helper (6b03c65)

[1.2.36] - 2020-10-06

Bundler

  • general: Fix bugs (#1141) (c127cb2)

[1.2.35] - 2020-10-04

Bug Fixes

  • (jsx) Drop extra spaces around jsx attributes (#1121) (ea09133)

  • (strip) Don't treat type-only exports as concrete references (#1126) (e4b8a0c)

Bundler

  • general: Fix bugs (#1105) (9879fa5)- general: Fix extra bugs (#1127) (205ce4e)

[1.2.34] - 2020-09-24

[1.2.33] - 2020-09-24

Bug Fixes

  • (strip) Fix Config::import_not_used_as_values (#1101) (a9c3072)

Miscellaneous Tasks

  • general: Bump version of wasm (#1102) (73671ec)

[1.2.32] - 2020-09-22

Codegen

  • general: Fix for jsx (#1097) (7e8ff1d)

[1.2.31] - 2020-09-22

Bundler

  • general: Handle export * properly (#1083) (fa756a1)

Resolver

  • general: Handle pattern in lhs of for of/in correctly (#1089) (ac0a19c)

Wasm

  • general: Automatic deployment (#1084) (7905b0d)

[1.2.30] - 2020-09-18

[1.2.29] - 2020-09-18

Bundler

  • general: Fix for deno (#1078) (24c597f)

Typescript_strip

  • general: Option to remove completely unused imports (#1060) (bc82b55)

[1.2.28] - 2020-09-13

[1.2.27-alpha.1] - 2020-09-13

Cjs

  • general: Fix import order (#1069) (8a01729)

Parser

  • general: Parse member expression is object patterns (#1068) (0972db9)

Resolver

  • general: No additional scope for function child (#1070) (f029115)- general: Correctly set in_type (#1071) (4d5a0da)

[1.2.26] - 2020-09-11

[1.2.25] - 2020-09-11

Bug Fixes

  • general: Handle conditional expression in callee (#1051) (9be8bf6)

Codegen

  • general: Don't emit newline after a block comment (#1062) (2fff66d)

Common_js

  • general: Change order of exports (#1057) (dc4c92c)

Jsdoc

  • general: Fix parser (#1059) (09e3f96)

Resolver

  • general: Handle constructor properly (#1054) (e2546e0)- general: Fix handling of constructor parameters (#1056) (aec155b)

[1.2.24] - 2020-09-08

[1.2.23] - 2020-09-07

[1.2.23-alpha.1] - 2020-09-07

Bug Fixes

  • (dep_graph) Top level dynamic import (#1024) (c4cc433)- general: Expose dep_graph crate (#1023) (9a073f1)- general: Handle binary expression in callee of new (#1030) (6524802)

[1.2.22] - 2020-08-30

[1.2.22-alpha.2] - 2020-08-30

[1.2.22-alpha.1] - 2020-08-30

[1.2.21] - 2020-08-24

[1.2.20] - 2020-08-15

Hygiene

  • general: No ref-ref conflict (#963) (01aeec3)

Spack

  • general: Allow using jsx (#971) (7387872)

[1.2.19] - 2020-08-13

[1.2.17] - 2020-08-10

[1.2.15] - 2020-08-09

[1.2.14] - 2020-08-08

[1.2.13] - 2020-08-07

[1.2.12] - 2020-08-06

[1.2.11] - 2020-08-02

[1.2.10] - 2020-07-31

Bug Fixes

  • general: Readonly is not stripped from private prop (#916) (9cb32cb)

Codegen

  • general: Preserve quotes (#911) (ca43112)

[1.2.9] - 2020-07-26

Cleanup

Spack

  • general: Remove_item is deprecated (#881) (053f81c)

[1.2.8] - 2020-07-05

[1.2.7] - 2020-07-01

Spack

  • general: More extensions for node resolver (#842) (aea757d)- general: Enhancement (#845) (31020e4)- general: Modules (#848) (66d42ad)

[1.2.1] - 2020-06-14

[1.2.0] - 2020-06-14

Spack

  • general: Super-fast bundler (#825) (fcef201)

[1.1.58] - 2020-06-12

Regenerator

  • general: Handle yield* correctly (#833) (5022999)

[1.1.56] - 2020-06-10

[1.1.53] - 2020-06-03

[1.1.52] - 2020-06-02

[1.1.51] - 2020-05-28

[1.1.50] - 2020-05-28

[1.1.49] - 2020-05-28

[1.1.48] - 2020-05-23

Typescript_strip

  • general: Handle types used only in casts (#794) (f117fed)

[1.1.46] - 2020-05-21

Resolver

  • general: Handle body of arrow functions correctly (#790) (5cc3efa)

[1.1.45] - 2020-05-19

[1.1.44] - 2020-05-18

[1.1.42] - 2020-05-09

Dce

  • general: Separate phase for dropping imports (#764) (ddc5ace)

[1.1.41] - 2020-05-05

[1.1.40] - 2020-04-30

[1.1.39] - 2020-04-10

[1.1.38] - 2020-04-05

[1.1.37] - 2020-03-28

[1.1.36] - 2020-03-26

[1.1.35] - 2020-03-13

[1.1.34] - 2020-03-09

[1.1.33] - 2020-03-05

[1.1.32] - 2020-03-04

[1.1.31] - 2020-03-01

[1.1.30] - 2020-02-29

[1.1.29] - 2020-02-25

Resolver

  • general: Handle hoisting correctly (#689) (363b835)

[1.1.28] - 2020-02-22

[1.1.27] - 2020-02-20

[1.1.26] - 2020-02-19

Resolver

  • general: Handle method property correctly (#679) (f79223e)

[1.1.25] - 2020-02-17

[1.1.24] - 2020-02-15

[1.1.23] - 2020-02-13

[1.1.22] - 2020-02-13

[1.1.21] - 2020-02-11

[1.1.19] - 2020-02-07

[1.1.18] - 2020-02-06

[1.1.17] - 2020-01-30

[1.1.16] - 2020-01-24

Block_scoping

  • general: Handle variable infection (#610) (480015d)

[1.1.15] - 2020-01-24

Hygiene

  • general: Fix handling of special identifiers (#603) (9be9ea2)

[1.1.14] - 2020-01-23

Bug Fixes

  • general: Fix as_bool treating bitor like bitand (#596)

(08ce8d0)

Hygiene

  • general: Handle use-use conflict (#599) (8ecbe14)

Regenerator

  • general: Allow nested finally block (#601) (20e37ea)

[1.1.13] - 2020-01-17

Resolver

  • general: Handle methods correctly (#579) (b7f8282)

[1.1.12] - 2020-01-08

Dce

  • general: Preserve nested if statement (#565) (3e0f4a5)

[1.1.11] - 2020-01-02

[1.1.10] - 2019-12-28

[1.1.9] - 2019-12-25

[1.1.8] - 2019-12-24

[1.1.7] - 2019-12-21

[1.1.6] - 2019-12-14

Bug Fixes

  • general: Fixup! Add a test for #503 (5076249)

Parser

  • general: Respect jsc.target (#507) (332061f)

[1.1.5] - 2019-12-11

[1.1.4] - 2019-12-09

[1.1.2] - 2019-12-02

[1.1.1] - 2019-12-01

[1.1.0] - 2019-11-30

Bug Fixes

  • general: Fixup! Don't omit empty values while serializing (41c6941)

[1.0.54] - 2019-11-24

[1.0.53] - 2019-11-23

Resolver

  • general: Handle arrow expression correctly (#462) (fa941b3)

[1.0.52] - 2019-11-20

Resolver

  • general: Handle hoisting (#455) (2106860)

[1.0.50] - 2019-11-18

Parser

  • general: Error recovery (#449) (d074063)

[1.0.49] - 2019-11-15

[1.0.48] - 2019-11-10

Bug Fixes

  • general: Fix typo (d73de6c)- general: Fix typo (06d2be4)- general: Fix links and use sudo (9ec8856)- general: Fix tests (92c7def)- general: Fixup! fix tests (59f11a8)- general: Fix

It's not rust code.. (f8ea0bd)- general: Fix parser tests (dc8e178)- general: Fix link (ed6ba04)- general: Fix swc_ecma_codegen (fd79f4e)- general: Fix a link in README.md (d4ef56e)- general: Fix a bug (90135ed)- general: Fix test imports for latest nightly (#355)

(6f97012)- general: Fix lints (fbbafc5)- general: Fix this in async generator (#425)

swc_ecma_transforms:

  • Don't delete test file when an execution test fails
  • fix #400 (3a637d4)- general: Fixup! Bump versions (2add7a0)

Miscellaneous Tasks

  • general: Cleanup for docs; no email from travis (056a11d)

Simplify

  • general: left.rhs * right is only safe when operators are the same (07bf194)

Es2015

  • general: :destructuring pass (#312) (b4a391b)

Readme

  • general: Fix npm install command (#89) (946a32a)

Swc_ecma_ast

  • general: - Split class member / property into separate types (a46804a)

Swc_ecma_transforms

  • general: - remove this parameter from typescript::strip pass (fixes #236) (4fddea0)

Travis

  • general: Fix doc upload (#47) (bbd9ec9)- general: Don't cache docs (4e21eb1)