SWC Bot
b4ae28b053
chore: Publish crates
2023-06-26 04:02:12 +00:00
Donny/강동윤
9d5dda1299
fix(es/parser): Adjust context while parsing type arguments of TypeScript type queries ( #7582 )
...
**Related issue:**
- Closes #7580 .
2023-06-26 04:00:00 +00:00
SWC Bot
fcd650c0e6
chore: Publish crates
2023-06-24 01:30:47 +00:00
OJ Kwon
ab7b17cf10
feat(plugin/runner): Update wasmer
to v4
( #7576 )
2023-06-24 01:28:50 +00:00
SWC Bot
4efefb0f4e
chore: Publish crates
2023-06-23 02:28:10 +00:00
Kieran Siek
95ac74e6e4
refactor(common): Remove add_bitflags
and update bitflags
( #7571 )
2023-06-23 11:26:22 +09:00
SWC Bot
068c17206a
chore: Publish crates
2023-06-22 14:26:37 +00:00
OJ Kwon
d86f8f6a3c
fix(estree/compat): Adjust loc.col
( #7565 )
2023-06-22 14:24:52 +00:00
SWC Bot
8c1436aaf5
chore: Publish crates
2023-06-22 13:40:52 +00:00
Donny/강동윤
d57d0d3ad3
build(cargo): Update deps ( #7566 )
2023-06-22 13:37:35 +00:00
SWC Bot
33355cf707
chore: Publish crates
2023-06-22 07:43:38 +00:00
Donny/강동윤
d12dc70c91
build(cargo): Update deps ( #7564 )
2023-06-22 07:40:41 +00:00
SWC Bot
f9c5265bde
chore: Publish crates
2023-06-21 15:44:11 +00:00
Donny/강동윤
54410047fa
build(deps): Update syn
to v2
( #7557 )
2023-06-21 15:38:46 +00:00
SWC Bot
c9f2838071
chore: Publish crates
2023-06-21 09:40:25 +00:00
Donny/강동윤
07a858030c
feat(es/minifier): Enable hoist_props
by default ( #7535 )
2023-06-21 18:38:35 +09:00
SWC Bot
2a32a4dc6a
chore: Publish crates
2023-06-21 09:07:16 +00:00
SWC Bot
690ca6c8e1
chore: Publish crates
2023-06-21 07:27:39 +00:00
Donny/강동윤
3ad07a7d2e
feat(es/minifier): Support __NO_SIDE_EFFECTS__
( #7532 )
...
**Related issue:**
- Closes #7525 .
2023-06-21 07:25:29 +00:00
SWC Bot
5b01fa92e7
chore: Publish crates
2023-06-21 06:34:40 +00:00
SWC Bot
c023a03d7b
chore: Publish crates
2023-06-21 03:18:22 +00:00
Donny/강동윤
46fb4619ba
feat(testing): Add CARGO_TARGET_DIR
and use it from other crates ( #7552 )
2023-06-21 03:16:33 +00:00
Donny/강동윤
5bee46263c
chore: Publish crates
2023-06-20 18:39:53 +09:00
SWC Bot
8b765e6763
chore: Publish crates
2023-06-20 05:37:57 +00:00
Donny/강동윤
6e5d8b3cf1
feat(es/codegen): Support preamble
( #7551 )
...
**Related issue:**
- Closes #7475 .
2023-06-20 14:35:46 +09:00
SWC Bot
f27d6ea58c
chore: Publish crates
2023-06-20 05:05:01 +00:00
Donny/강동윤
1d9f972fb4
fix(es/resolver): Resolve the super class before registering a class name ( #7550 )
...
**Related issue:**
- Closes #7546 .
2023-06-20 05:03:01 +00:00
SWC Bot
69b034931e
chore: Publish crates
2023-06-20 04:14:44 +00:00
Donny/강동윤
bc6e95052e
fix(es/compat): Visit arrow body from optional chaining pass ( #7549 )
...
**Related issue:**
- Closes #7547 .
2023-06-20 04:12:31 +00:00
SWC Bot
fec056f5db
chore: Publish crates
2023-06-20 03:21:20 +00:00
Donny/강동윤
862f095e65
test(es): Add one more test for a wrong issue ( #7545 )
...
**Related issue:**
- Closes #7513 .
2023-06-20 03:19:20 +00:00
SWC Bot
17e339fc26
chore: Publish crates
2023-06-20 01:54:14 +00:00
Curtis Wilson
8cfc4f9e9a
fix(es/preset-env): Don't log Yield
to the console ( #7548 )
...
**Description:**
When a `yield` token is encountered by the parser, the word "Yield" is unnecessarily logged to the console. This PR removes the extra logging.
2023-06-20 01:52:24 +00:00
SWC Bot
8f1c8ea9fa
chore: Publish crates
2023-06-19 06:36:31 +00:00
Donny/강동윤
1d84e952fe
fix(es): Accept parse
option for minify()
( #7543 )
...
**Description:**
We don't support them. but this is to make API more compatible with `terser`.
**Related issue:**
- Closes #7455 .
2023-06-19 06:34:44 +00:00
SWC Bot
44aac8fe27
chore: Publish crates
2023-06-19 05:51:51 +00:00
Donny/강동윤
aa82e5fff3
test(plugin/runner): Share target
directory ( #7544 )
...
**Description:**
This will reduce CI time greatly.
2023-06-19 05:49:45 +00:00
SWC Bot
2f2a15f3df
chore: Publish crates
2023-06-19 05:01:43 +00:00
Donny/강동윤
70bc605c67
test(es): Add a test for a wrong issue ( #7542 )
...
**Related issue:**
- Closes #7513 .
2023-06-19 04:59:28 +00:00
Donny/강동윤
d1430c00b4
chore: Publish crates
2023-06-19 12:36:16 +09:00
Donny/강동윤
fe1a545e65
chore: Publish crates
2023-06-19 12:26:07 +09:00
SWC Bot
2669fc214a
chore: Publish crates
2023-06-19 03:20:19 +00:00
Donny/강동윤
76aa91f83c
fix(es/typescript): Don't panic of @jsxFrag null
( #7540 )
...
**Related issue:**
- Closes #7539 .
2023-06-19 12:18:19 +09:00
SWC Bot
d38c40914e
chore: Publish crates
2023-06-19 03:02:08 +00:00
Justin Ridgewell
990e48e0e8
fix(es/compat): Fix optional chaining ( #7530 )
...
**Description:**
This fixes a few bugs with optional chaining:
-
[`a?.c()`](https://play.swc.rs/?version=1.3.64&code=H4sIAAAAAAAAA9PXVwjOyC%2FNSVFISrXi0tdXSFSwtVXIK83JUbBXKM1LSU3LzEtNUbBSSNRL1tC05kq0h9AAouc%2F7DgAAAA%3D&config=H4sIAAAAAAAAA2VSu27DMAzc8xUC5wAZii7ZWnRJgXTKDxAKkyrQwyDpNEbgf69kxI4jexAk3olH3fm%2BMgYoXsFszT3vywchHQm2pa7cwXos28T0LRl4m0qnxJY%2BvD8wRsmHUGDllibGsYsYnN2FJrHWoCKfScudUbsv2LDARewEgI4CM24uezqj7b4oj4aauOpf5EdoT4pHVFxSmNDqS1tjNhvDbVQXKNuAraaA6iysC5DYWI8izs4uwIMOC%2F6cpL%2Bc%2FnanHwwkDVpaDJM5rdBn67y6WHv5eNCVfGpCzibDJ%2FQyw%2Fv1qtqAT0lqHWiQhfjVSumi4m2I3QYUy65RmNl0kdtS8OlvPWxfhTw0lnd45pv%2FstbTLOKuGeyzKYQULwIT08l%2B5BaJVf8PfP2zz7YCAAA%3D )
-
[`a?.b.c()`](https://play.swc.rs/?version=1.3.64&code=H4sIAAAAAAAAA9PXVwjOyC%2FNSVFISrXi0tdXSFSwtVXIK83JUbBXKM1LSU3LzEtNUbBSSNRL0kvW0LTmSrSHsQBsP8xLPAAAAA%3D%3D&config=H4sIAAAAAAAAA2VSu27DMAzc8xUC5wAZii7ZWnRJgXTKDxAKkyrQwyDpNEbgf69kxI4jexAk3olH3fm%2BMgYoXsFszT3vywchHQm2pa7cwXos28T0LRl4m0qnxJY%2BvD8wRsmHUGDllibGsYsYnN2FJrHWoCKfScudUbsv2LDARewEgI4CM24uezqj7b4oj4aauOpf5EdoT4pHVFxSmNDqS1tjNhvDbVQXKNuAraaA6iysC5DYWI8izs4uwIMOC%2F6cpL%2Bc%2FnanHwwkDVpaDJM5rdBn67y6WHv5eNCVfGpCzibDJ%2FQyw%2Fv1qtqAT0lqHWiQhfjVSumi4m2I3QYUy65RmNl0kdtS8OlvPWxfhTw0lnd45pv%2FstbTLOKuGeyzKYQULwIT08l%2B5BaJVf8PfP2zz7YCAAA%3D )
-
[`a.c?.()`](https://play.swc.rs/?version=1.3.64&code=H4sIAAAAAAAAAxWKsQ3AIAwEe6b4Ehq7J0IMkQGQYxMlkkUq9g80d1ccM87nm264eg7MiE2aomwvSiJNKAVjuqNiDuv3O7ohY4%2Bk4r7WdAQhrRRX%2FIwaKV1TAAAA&config=H4sIAAAAAAAAA2VSu27DMAzc8xUC5wAZii7ZWnRJgXTKDxAKkyrQwyDpNEbgf69kxI4jexAk3olH3fm%2BMgYoXsFszT3vywchHQm2pa7cwXos28T0LRl4m0qnxJY%2BvD8wRsmHUGDllibGsYsYnN2FJrHWoCKfScudUbsv2LDARewEgI4CM24uezqj7b4oj4aauOpf5EdoT4pHVFxSmNDqS1tjNhvDbVQXKNuAraaA6iysC5DYWI8izs4uwIMOC%2F6cpL%2Bc%2FnanHwwkDVpaDJM5rdBn67y6WHv5eNCVfGpCzibDJ%2FQyw%2Fv1qtqAT0lqHWiQhfjVSumi4m2I3QYUy65RmNl0kdtS8OlvPWxfhTw0lnd45pv%2FstbTLOKuGeyzKYQULwIT08l%2B5BaJVf8PfP2zz7YCAAA%3D )
-
[`a.b.c?.()`](https://play.swc.rs/?version=1.3.64&code=H4sIAAAAAAAAAyWLsQ3AIAwEe6b4Ehq7J0IMkQEQ2ESJZJGK%2FYNCdVfcMeO832mK1qNjhi%2B1tCJI2xYrtUASkBLGNEPGHNqvZ3RFxM5Jqtk%2FhMOtgSSTX%2FoBjF6UKV8AAAA%3D&config=H4sIAAAAAAAAA2VSu27DMAzc8xUC5wAZii7ZWnRJgXTKDxAKkyrQwyDpNEbgf69kxI4jexAk3olH3fm%2BMgYoXsFszT3vywchHQm2pa7cwXos28T0LRl4m0qnxJY%2BvD8wRsmHUGDllibGsYsYnN2FJrHWoCKfScudUbsv2LDARewEgI4CM24uezqj7b4oj4aauOpf5EdoT4pHVFxSmNDqS1tjNhvDbVQXKNuAraaA6iysC5DYWI8izs4uwIMOC%2F6cpL%2Bc%2FnanHwwkDVpaDJM5rdBn67y6WHv5eNCVfGpCzibDJ%2FQyw%2Fv1qtqAT0lqHWiQhfjVSumi4m2I3QYUy65RmNl0kdtS8OlvPWxfhTw0lnd45pv%2FstbTLOKuGeyzKYQULwIT08l%2B5BaJVf8PfP2zz7YCAAA%3D )
-
[`a?.b[c?.d]`](https://play.swc.rs/?version=1.3.64&code=H4sIAAAAAAAAA9PXVwjOyC%2FNSVFISrXi0tdX0IhPVLBVSNRUsLVVyCvNyVGwVyjLz0xRMFCwUohP1EuK1ohPBipIxq4gWS8l1por0R6oLtkezAYAJs%2FWxmEAAAA%3D&config=H4sIAAAAAAAAA2VSu27DMAzc8xUC5wAZii7ZWnRJgXTKDxAKkyrQwyDpNEbgf69kxI4jexAk3olH3fm%2BMgYoXsFszT3vywchHQm2pa7cwXos28T0LRl4m0qnxJY%2BvD8wRsmHUGDllibGsYsYnN2FJrHWoCKfScudUbsv2LDARewEgI4CM24uezqj7b4oj4aauOpf5EdoT4pHVFxSmNDqS1tjNhvDbVQXKNuAraaA6iysC5DYWI8izs4uwIMOC%2F6cpL%2Bc%2FnanHwwkDVpaDJM5rdBn67y6WHv5eNCVfGpCzibDJ%2FQyw%2Fv1qtqAT0lqHWiQhfjVSumi4m2I3QYUy65RmNl0kdtS8OlvPWxfhTw0lnd45pv%2FstbTLOKuGeyzKYQULwIT08l%2B5BaJVf8PfP2zz7YCAAA%3D )
- [`delete
foo?.bar`](https://play.swc.rs/?version=1.3.64&code=H4sIAAAAAAAAA9PXVwjOyC%2FNSVFISrXi0tdXSMvPV7C1VcgrzclRsFcoKSpNVbBSSEnNSS1JBcnpJSUWcSG49iA%2BAGcLTstEAAAA&config=H4sIAAAAAAAAA1WPSw7CMAxE9zlF5DULYIEEd%2BAQVnCrVPkpTiWqqncnTZMAO3vG42evQkqYWMFDrrnMTcDIFHufFV5cwndWgJRFVlGHBKfmTrxbAxqmIm2HAwnjSKmk%2BHq%2B3GsCjPdMWU5xpipZ7fSw%2FCKVtyESc9vcaRbdaOgfKCoUrH%2FNxayvpCXQccANvkMN1heD5mdL7leJ7QOQNa2NFgEAAA%3D%3D )
- [`function foo(a, b = a?.b)
{}`](https://play.swc.rs/?version=1.3.64&code=H4sIAAAAAAAAA9PXVwjOyC%2FNSVFISrXi0tdXSCvNSy7JzM9TSMvP10jUUUhSsFXQ0NBUsLVTqFYoSyxSiE%2B0VnjUsEyhVlNDU1OhupYLm45Ee70kkCQAp8DQOl8AAAA%3D&config=H4sIAAAAAAAAA22Rz07DMAzG73uKyOdJAw5I7Ii4cBjvYKXuyJQ%2Fle3AqmnvTltIm63cHH%2B%2F%2BPtkXzbGwEks7M1lKIeHMkZpE4e5NbU9HdH2b2QToyYeROVM2wVoinQgxQYV1wgTWr0Za8xuZzhHdYH2BjBrCqjOwnYUEhvrUcTZ6gP84bDia0g%2FOX2%2Ftx8YSDq0tAozMFnoNTuvLsp%2FckNf5FMXKI6ZW%2FRS6ddSzgX4lOTeBzpkIb5dpfRR8TzmJxtQLLtOoVrTSc5rw2W%2F92GXBIp8JJ0Gy9PD48s0dJIhpCZ7qq7cd%2FQLPsMMOTkUrBhAcNG1fcmzuf4AkV7gUzECAAA%3D )
It also optimizes the AST for runtime evaluation. Before, we constructed
a leftwards conditional tree (`(_a_b = (_a = a) == null ? void 0 : _a.b)
== null ? void 0 : _a_b.c`) instead of a rightward tree (`(_a = a) ==
null ? void 0 : (_a_b = _a.b) == null ? void 0 : _a_b.c`), which
required multiple `== null` checks after the first nullish is found.
**Related issue:**
- Closes #7531 .
2023-06-19 12:00:11 +09:00
SWC Bot
0859b76ed0
chore: Publish crates
2023-06-16 06:46:25 +00:00
Donny/강동윤
f42fdd21af
fix(es/module): Add "use strict"
while preserving directives ( #7537 )
...
**Related issue:**
- Closes #7536 .
2023-06-16 06:44:28 +00:00
SWC Bot
b9acc83fa7
chore: Publish crates
2023-06-16 02:59:35 +00:00
Donny/강동윤
3e9dd88e37
feat(es/module): Preserve custom use
directives ( #7528 )
...
**Related issue:**
- Closes #7315 .
2023-06-16 11:50:52 +09:00
Donny/강동윤
37c7296913
chore: Publish crates
2023-06-14 14:08:15 +09:00
SWC Bot
39276402bf
chore: Publish crates
2023-06-14 05:01:49 +00:00
Donny/강동윤
4644d005d2
fix(es/compat): Fix handling of this
of optional chaining pass ( #7527 )
...
**Related issue:**
- Closes #7526 .
2023-06-14 13:59:35 +09:00
SWC Bot
db85bf3ee2
chore: Publish crates
2023-06-13 16:14:41 +00:00
Donny/강동윤
f27838dedc
fix(es/codegen): Fix regression of source maps ( #7523 )
...
**Related issue:**
- Closes #7506 .
2023-06-13 16:12:45 +00:00
SWC Bot
275db1baec
chore: Publish crates
2023-06-13 03:39:28 +00:00
廖应龙
a0da02d0ff
fix(es/codegen): Emit type arguments of jsx element names ( #7522 )
2023-06-13 03:37:39 +00:00
Donny/강동윤
e773efc3a8
chore: Publish crates
2023-06-12 21:33:11 +09:00
SWC Bot
08574e690b
chore: Publish crates
2023-06-12 08:04:50 +00:00
Donny/강동윤
3958f1792c
refactor(es/ast): Remove unused fields ( #7518 )
...
**Related issue:**
- Closes #7347 .
- Closes #7487 .
2023-06-12 08:02:34 +00:00
SWC Bot
96895b1f3f
chore: Publish crates
2023-06-12 06:49:35 +00:00
Donny/강동윤
aa83584634
refactor(es/ast): Reimplement optional chaining ( #7441 )
...
**Related issue:**
- Closes #7003 .
- Closes #7156 .
2023-06-12 06:47:40 +00:00
SWC Bot
d8f5158963
chore: Publish crates
2023-06-12 02:24:36 +00:00
Austaras
8e933c8a9f
fix(es/react): Default to empty string when emitting refresh signature ( #7514 )
...
**Related issue:**
- Closes #7471 .
2023-06-12 02:22:31 +00:00
SWC Bot
cea1237c5e
chore: Publish crates
2023-06-12 01:39:32 +00:00
Pig Fang
6c00a2422a
feat(es/parser): Disallow tagged tpl in optional chaining ( #7515 )
2023-06-12 01:37:39 +00:00
SWC Bot
b46bcf3f50
chore: Publish crates
2023-06-08 05:08:56 +00:00
Donny/강동윤
cc4146c9d3
fix(es/compat): Make stage 3 decorator pass use correct state for inner classes ( #7508 )
...
**Related issue:**
- Closes #7499 .
2023-06-08 05:06:51 +00:00
SWC Bot
37634a758d
chore: Publish crates
2023-06-08 04:15:29 +00:00
Austaras
7f9f0b8bce
fix(es/minifier): Infect mutation when assigning a property ( #7503 )
2023-06-08 04:13:42 +00:00
SWC Bot
3fe1236fe0
chore: Publish crates
2023-06-08 03:28:07 +00:00
Donny/강동윤
d545df6dd9
perf(css/prefixer): Convert macro to a function call to reduce binary size ( #7507 )
...
**Related issue:**
- https://github.com/vercel/next.js/pull/50365
2023-06-08 03:26:19 +00:00
SWC Bot
eeac6fa68a
chore: Publish crates
2023-06-08 02:21:20 +00:00
OJ Kwon
73929fc43c
feat(plugin/runner): Support shared wasix runtime ( #7504 )
2023-06-08 02:19:07 +00:00
SWC Bot
89bee900e4
chore: Publish crates
2023-06-07 05:10:31 +00:00
David Sherret
064bcf4854
fix(es/codegen): Remove extra spaces in AssignPatProp
and KeyValuePatProp
( #7488 )
...
Co-authored-by: Donny/강동윤 <kdy1997.dev@gmail.com>
2023-06-07 05:08:35 +00:00
SWC Bot
f634c3ad2f
chore: Publish crates
2023-06-07 04:25:48 +00:00
Austaras
62075faeaa
feat(es/minifier): Remove unused labels ( #7478 )
2023-06-07 04:23:40 +00:00
SWC Bot
b6b4b0fd2e
chore: Publish crates
2023-06-07 03:03:16 +00:00
David Sherret
a343e7ccae
feat(es/codegen): Add ability to set indentation string via rust api ( #7494 )
...
**Description:**
This adds the ability to set the indentation string of JsWriter via the Rust API. The motivation behind this change is to allow people to use other indentations in the emit output like tabs or two spaces via the Rust API.
2023-06-07 03:01:16 +00:00
SWC Bot
61dc611da3
chore: Publish crates
2023-06-05 04:47:07 +00:00
Donny/강동윤
abd62bc797
perf(es): Use &dyn Comments
for jsx and TypeScript ( #7490 )
2023-06-05 13:44:38 +09:00
SWC Bot
47dc78f607
chore: Publish crates
2023-06-05 04:06:15 +00:00
Donny/강동윤
2c3ac682e2
perf(es): Use &dyn Comments
to reduce binary size ( #7489 )
...
**Related issue:**
- https://github.com/vercel/next.js/pull/50365
2023-06-05 13:04:08 +09:00
Donny/강동윤
ddb5635ebf
chore: Publish crates
2023-06-03 18:23:17 +09:00
SWC Bot
b190879a51
chore: Publish crates
2023-06-03 07:07:33 +00:00
Donny/강동윤
decebadff1
chore: Publish crates
2023-06-03 00:44:10 +09:00
SWC Bot
b71222b086
chore: Publish crates
2023-06-02 15:36:55 +00:00
SWC Bot
9de08611e1
chore: Publish crates
2023-06-02 15:24:25 +00:00
Donny/강동윤
65ce5d1081
perf(es/minifier): Make minifier not overly generic ( #7483 )
...
**Description:**
Generics cause binary bloat.
**Related issue:**
- https://github.com/vercel/next.js/pull/50365
2023-06-03 00:22:30 +09:00
SWC Bot
d6bbbc332d
chore: Publish crates
2023-05-31 01:59:26 +00:00
Donny/강동윤
e506635f74
fix(es/minifier): Don't generate generator arrows ( #7466 )
...
**Related issue:**
- Closes #7457 .
2023-05-31 01:57:13 +00:00
Donny/강동윤
ad8e6a006c
chore: Publish crates
2023-05-30 14:41:39 +09:00
SWC Bot
a63905aa2c
chore: Publish crates
2023-05-30 05:18:06 +00:00
OJ Kwon
56ac9eb6b3
feat(common): Enable bytecheck for missing structs ( #7465 )
2023-05-30 05:15:46 +00:00
SWC Bot
a29ef90589
chore: Publish crates
2023-05-30 04:37:04 +00:00
Donny/강동윤
8274cce9a7
test(es/parser): Add a test for a fixed issue ( #7467 )
...
**Related issue:**
- Closes #7456 .
2023-05-30 04:35:07 +00:00
SWC Bot
076b4d4023
chore: Publish crates
2023-05-30 03:24:10 +00:00
David Sherret
3935d02e36
fix(es/codegen): Emit ;
for TsImportEqualsDecl
( #7464 )
2023-05-30 03:22:07 +00:00
SWC Bot
81a413b332
chore: Publish crates
2023-05-28 14:12:53 +00:00
OJ Kwon
1868d36cfe
fix(plugin/runner): Disable wasi_env
cleanup ( #7458 )
2023-05-28 14:11:01 +00:00
SWC Bot
dcda6498f3
chore: Publish crates
2023-05-28 13:29:30 +00:00
Donny/강동윤
e15adaf6ea
chore(es/preset-env): Update data ( #7459 )
2023-05-28 13:27:38 +00:00
SWC Bot
15217a1f9e
chore: Publish crates
2023-05-25 05:40:33 +00:00
suxin2017
d370324cfd
fix(css/modules): Don't drop the correct selector ( #7450 )
...
**Related issue:**
- Closes #7447 .
2023-05-25 05:38:41 +00:00
SWC Bot
a85816d505
chore: Publish crates
2023-05-25 04:54:11 +00:00
Donny/강동윤
77850dd8f0
fix(es/parser): Fix parsing of generic jsx element name ( #7449 )
...
**Related issue:**
- Closes #7444 .
2023-05-25 13:52:14 +09:00
SWC Bot
8d52500a9a
chore: Publish crates
2023-05-25 04:00:53 +00:00
Austaras
0cd2b61b05
feat(es/minifier): Inline for loop variables ( #7445 )
2023-05-25 03:59:02 +00:00
Donny/강동윤
c856808f61
chore: Publish crates
2023-05-25 11:25:07 +09:00
SWC Bot
1b5aa4a09b
chore: Publish crates
2023-05-25 02:17:22 +00:00
limerick
0c92e534a5
fix(es): Ignore input sourcemap error ( #7446 )
2023-05-25 11:15:21 +09:00
SWC Bot
6c3ff01a53
chore: Publish crates
2023-05-24 07:48:00 +00:00
Donny/강동윤
e83368e574
refactor(visit): Reduce expanded LOCs ( #7442 )
...
**Description:**
x-ref: https://vercel.slack.com/archives/C03EWR7LGEN/p1684898884673379
**Related issue:**
- https://github.com/web-infra-dev/rspack/issues/3058 .
2023-05-24 07:45:40 +00:00
SWC Bot
c1f2b4a09f
chore: Publish crates
2023-05-24 06:59:37 +00:00
Donny/강동윤
a37d59a134
fix(es/parser): Fix parsing of tsx with a type annotation in a conditional expression ( #7440 )
...
**Related issue:**
- Closes #7224 .
2023-05-24 15:57:50 +09:00
SWC Bot
b95cd8444e
chore: Publish crates
2023-05-24 06:27:35 +00:00
Donny/강동윤
33a922b6f8
fix(es/parser): Allow using package
as a parameter name in interface ( #7438 )
...
**Related issue:**
- Closes #7186 .
2023-05-24 06:25:39 +00:00
SWC Bot
f9f0cc2380
chore: Publish crates
2023-05-24 05:44:06 +00:00
Donny/강동윤
f3d660f972
fix(es/compat): Fix variable scoping of object rest pass. ( #7437 )
...
**Related issue:**
- Closes #6988 .
2023-05-24 05:41:57 +00:00
SWC Bot
c14306c914
chore: Publish crates
2023-05-24 04:52:50 +00:00
OJ Kwon
786cf3a10f
fix(es): Init filesystem cache only if plugin exists ( #7436 )
2023-05-24 04:50:51 +00:00
SWC Bot
552bc0ba18
chore: Publish crates
2023-05-23 07:16:28 +00:00
Donny/강동윤
2071f89d4e
fix(es/preset-env): Fix pass ordering ( #7434 )
...
**Related issue:**
- Closes #6898 .
- Closes #7432 .
2023-05-23 07:14:37 +00:00
SWC Bot
8872b41272
chore: Publish crates
2023-05-23 06:25:54 +00:00
Donny/강동윤
97d0f79142
fix(es/compat): Fix stage 3 decorator pass ( #7392 )
2023-05-23 06:24:05 +00:00
SWC Bot
47114702ef
chore: Publish crates
2023-05-23 05:30:42 +00:00
Donny/강동윤
1cab43f17d
fix(es/parser): Reset class context ( #7433 )
...
**Related issue:**
- Closes #7428 .
2023-05-23 05:28:56 +00:00
SWC Bot
ed9d316833
chore: Publish crates
2023-05-22 05:29:02 +00:00
OJ Kwon
558ca40b99
fix(swc_core): Correctly expose plugin with host ( #7427 )
...
**Description:**
Following up https://github.com/swc-project/swc/pull/7422 , `swc_core::plugin` itself is not exposed to `__plugin_transform_host`, so still not able to access the inner plugin proxy.
2023-05-22 05:27:01 +00:00
SWC Bot
7964e1cb78
chore: Publish crates
2023-05-22 04:09:40 +00:00
OJ Kwon
cfdd407896
refactor(swc_core): Make common_plugin_transform
agnostic to mode ( #7422 )
2023-05-22 04:07:55 +00:00
SWC Bot
12b966ea21
chore: Publish crates
2023-05-22 03:23:50 +00:00
Donny/강동윤
66d52ec849
fix(es/compat): Fix destructuring handling of block_scoping
( #7425 )
...
**Related issue:**
- Closes #7418 .
2023-05-22 03:21:50 +00:00
SWC Bot
344a6ea7be
chore: Publish crates
2023-05-20 04:47:53 +00:00
OJ Kwon
c03a74c198
refactor(plugin/runner): Add attributes to the module bytes ( #7419 )
2023-05-20 04:46:09 +00:00
SWC Bot
920013511b
chore: Publish crates
2023-05-20 04:00:44 +00:00
OJ Kwon
f8fe365c3b
feat(plugin/runner): Enable in-memory precompiled module cache ( #7420 )
2023-05-20 03:58:55 +00:00
Donny/강동윤
0ac3aebe3d
chore: Publish crates
2023-05-19 14:25:31 +09:00
SWC Bot
b2c9bb47a0
chore: Publish crates
2023-05-19 04:37:45 +00:00
Austaras
40d2bf7ec3
fix(es/minifier): Prevent inlining vars assigned outside current function scope ( #7414 )
...
**Related issue:**
- Closes #7412 .
2023-05-19 13:35:50 +09:00
SWC Bot
135c4fd16b
chore: Publish crates
2023-05-18 08:20:26 +00:00
Donny/강동윤
57ad722d06
fix(es/parser): Fix parsing of >
in typescript mode ( #7407 )
...
**Related issue:**
- Closes #7403 .
2023-05-18 08:18:27 +00:00
SWC Bot
9440f4b196
chore: Publish crates
2023-05-18 07:08:08 +00:00
OJ Kwon
ac5ab607c9
refactor(plugin/runner): Revise cache, module loading ( #7408 )
...
**Description:**
One of the oversight around design of `TransformExecutor` is
encapsulating plugin module logic. It has access to the cache and do its
own loading & storing. This means consumer of plugin runner have tricky
challenge to control its caching system. First, there is no way to
escape how swc_plugin_runner controls cache and cannot synchronize into
their own, also depends on the usecases cannot control the features they
want to opt in: for example, there's no way one interface uses in-memory
cache, and another uses filesystem since it is compile time configured
singleton.
PR revisits overall design of TransformExecutor: now it accepts a tratir
`PluginModuleBytes`, which abstracts any kind of bytes we are dealing
with, such as raw file slice or serialized `wasmer::Module`. Cache
instantiation and managing is now bubbled up to the application level
(`swc` in here), so if someone wants non-singleton caching or integrate
into their own caching system it can be customized.
Lastly, deprecated `memory_cache` feature and only exposes
`filesystem_cache`. Cache implementation uses in-memory is always
available, and can opt in filesystem cache where it's supported.
**BREAKING CHANGE:**
This is clearly breaking changes for the consumers of swc_core. for the
@swc/core, this PR takes care of necessary changes. I'll work on
next-swc changes later once we have new @swc/core version with this
changes.
2023-05-18 07:05:39 +00:00
SWC Bot
31d7b88555
chore: Publish crates
2023-05-18 01:21:08 +00:00
Austaras
5dbbbea2ef
fix(es/minifier): Mark all function params as potential property mutation ( #7409 )
...
**Description:**
This issue is more severe than I originally thought. It raises not in
array indexing, but in function calls and property mutation. We should
treat all function arguments as potentially be property mutated,
otherwise following example
```js
class A {
a = 1
toString() {
return this.a
}
}
const a = new A()
function foo(x) {
x.a++
}
const b = a + 1
foo(a)
console.log(b)
```
would be error(It should log 2, but logs 3 after compress).
As the result, massive regressions is unavoidable, since some of these
optimizations may indeed cause error. Part of them can be mitigated with
following optimization -- allow inline of ident even if its original
value is mutated. Consider
```js
export function foo(x) {
const y = x
x.a = 1
y.b = 2
}
```
If x is a primitive value, all mutations to its properties are ignored;
if x is a object, then y refers to the same object no matter what
mutation is performed.
And there's still room for more, currently following code
```js
export function foo(x) {
const y = Math.floor(x);
g(y);
}
```
But I'd rather do it in a separate PR.
**Related issue:**
- Closes #7402 .
2023-05-18 01:19:17 +00:00
SWC Bot
a2a544a0ae
chore: Publish crates
2023-05-17 13:12:20 +00:00
Yunfei He
dba78a0031
fix(es/compat): Mark reserved function names private ( #7298 )
2023-05-17 13:10:27 +00:00
SWC Bot
c520e7469e
chore: Publish crates
2023-05-17 06:17:15 +00:00
Donny/강동윤
95291f2c5d
fix(common): Disable tracing/release_max_level_info
( #7401 )
2023-05-17 06:15:18 +00:00
SWC Bot
8052d4dabd
chore: Publish crates
2023-05-17 04:53:45 +00:00
Donny/강동윤
1d3f32056c
fix(es/parser): Fix parsing of module
identifier ( #7400 )
...
**Related issue:**
- Closes #4176 .
- Closes #7372 .
2023-05-17 04:51:57 +00:00
SWC Bot
820f29ffc1
chore: Publish crates
2023-05-17 03:57:12 +00:00
Donny/강동윤
6b92eecd39
test(css/module): Add a test for a fixed issue ( #7399 )
...
**Related issue:**
- Closes #6897 .
2023-05-17 03:55:24 +00:00
SWC Bot
227c272904
chore: Publish crates
2023-05-16 12:33:08 +00:00
Donny/강동윤
eaba323581
test(es/parser): Add a test for a fixed issue ( #7398 )
...
**Related issue:**
- Closes #6976 .
2023-05-16 12:31:05 +00:00
SWC Bot
da0c612d85
chore: Publish crates
2023-05-16 05:18:57 +00:00
Donny/강동윤
3a0565f377
chore(plugin): Update rkyv
to v0.7.42
( #7397 )
2023-05-16 14:17:12 +09:00
SWC Bot
d3db7edd51
chore: Publish crates
2023-05-16 04:14:36 +00:00
Donny/강동윤
40ba242076
fix(es/codegen): Do not create duplicate source map entry ( #7309 )
2023-05-16 04:12:46 +00:00
SWC Bot
02b22f7625
chore: Publish crates
2023-05-16 03:23:16 +00:00
Donny/강동윤
f9cdd741c2
test(es/minifier): Enable more terser tests ( #7396 )
2023-05-16 03:21:08 +00:00
Donny/강동윤
4a53951fe3
chore: Publish crates
2023-05-15 13:18:22 +09:00
SWC Bot
a05e28906b
chore: Publish crates
2023-05-15 04:14:42 +00:00
OJ Kwon
05b4c11497
feat(swc_core): Expose plugin proxy to the host env ( #7391 )
2023-05-15 13:12:33 +09:00
Donny/강동윤
8e6fea8519
chore: Publish crates
2023-05-15 12:42:54 +09:00
SWC Bot
5e3d156aca
chore: Publish crates
2023-05-15 03:20:03 +00:00
OJ Kwon
bba1fad35c
feat(plugin): Add versioned wrapper struct ( #7382 )
2023-05-15 03:17:31 +00:00
SWC Bot
5d30437206
chore: Publish crates
2023-05-15 02:27:59 +00:00
Donny/강동윤
cad18fae4b
feat(es/compat): Implement auto accessors fully ( #7370 )
...
**Related issue:**
- Closes #7193 .
2023-05-15 02:26:07 +00:00
SWC Bot
a2577adffa
chore: Publish crates
2023-05-14 06:08:33 +00:00
OJ Kwon
e3868a7e00
feat(swc_core): Allow native env plugin to use memory cache ( #7390 )
...
**Description:**
I just realized there could be some case who'll want plugin in native env, but without filesystem cache. If there's a custom cache implementation, it'll make a conflict to swc's caching mechanism since swc does not expose any interface to the its cache.
PR takes simple approach to expose another feature to opt in native env with memory cache for those case. Ideally we should make `plugin_transform_host_native` to not to opt-in any cache, and then make `swc_plugin_runner` to run without any cache implementation - but that'll be a breaking changes with few more involved changes.
2023-05-14 06:06:24 +00:00
SWC Bot
a71d5b2180
chore: Publish crates
2023-05-14 05:23:11 +00:00
Austaras
fa7a3521f5
fix(es/parser): Fix >=
with type instantiate ( #7388 )
2023-05-14 05:21:13 +00:00
SWC Bot
e88ae37a0c
chore: Publish crates
2023-05-12 00:47:49 +00:00
OJ Kwon
9b3a41c57d
refactor(common): Derive ByteCheck
for ArcString
( #7380 )
2023-05-12 09:45:59 +09:00
SWC Bot
7655aaa42a
chore: Publish crates
2023-05-11 14:02:24 +00:00
Donny/강동윤
166e77c2b3
chore(es): Enable tracing spans for release builds ( #7379 )
2023-05-11 13:59:53 +00:00
SWC Bot
65785bdf21
chore: Publish crates
2023-05-10 04:19:21 +00:00
Donny/강동윤
041b491466
feat(es/parser): Implement explicit resource management ( #7322 )
...
**Description:**
- Add `UsingDecl`.
- Add `UsingDecl` to `Decl`.
- Rename `VarDeclOrPat` to `ForHead`.
- Add `UsingDecl` to `ForHead`.
- Implement parser for using declarations.
**Related issue:**
- #7316 .
2023-05-10 04:16:44 +00:00
SWC Bot
6432e1f5c5
chore: Publish crates
2023-05-10 03:33:12 +00:00
Donny/강동윤
1dced17998
fix(es/minifier): Fix remapping of vars upon inlining ( #7362 )
...
**Related issue:**
- Closes #7331 .
2023-05-10 03:31:15 +00:00
SWC Bot
e1c9182e1c
chore: Publish crates
2023-05-09 05:47:00 +00:00
Donny/강동윤
97ec259144
feat(es/compat): Partially support auto accessors ( #7364 )
...
**Description:**
I'll create a follow-up PR for a full support for auto accessors.
**Related issue:**
- #7193 .
2023-05-09 05:45:16 +00:00
SWC Bot
d8a3310543
chore: Publish crates
2023-05-09 03:04:13 +00:00
SWC Bot
7fc9b00443
chore: Publish crates
2023-05-08 03:40:27 +00:00
Donny/강동윤
9c052db796
feat(es/compat): Support export class
from stage 3 decorator pass ( #7363 )
...
**Related issue:**
- Closes #7358 .
2023-05-08 03:38:43 +00:00
SWC Bot
aef5ac4812
chore: Publish crates
2023-05-06 03:56:38 +00:00
OJ Kwon
d2c1f45f5a
feat(plugin): Enable bytecheck ( #7280 )
...
**Description:**
Second attempt to enable bytecheck. This PR does not have versioned struct yet, just enabling bytecheck wherever possible. Also, it is for the ast only yet, so transform metadata and others might need this later.
PR seems to be passing all the ci, but as we've experienced before, there might be some unexpected outcomes with the release. Maybe better to hold this until clear https://github.com/swc-project/swc/issues/7238 , then land as a separate release.
2023-05-06 03:54:25 +00:00
SWC Bot
b60a33001a
chore: Publish crates
2023-05-05 08:22:21 +00:00
Cong-Cong Pan
b180d09e1d
fix(xml/codegen): Escape <
and >
in child ( #7351 )
2023-05-05 08:20:09 +00:00
SWC Bot
5e595e7644
chore: Publish crates
2023-05-05 07:28:53 +00:00
OJ Kwon
4e278befcf
build(cargo): Update wasmer
to v3.3
( #7352 )
2023-05-05 07:26:38 +00:00
SWC Bot
e9f3371c5f
chore: Publish crates
2023-05-02 02:13:33 +00:00
Donny/강동윤
e0de83e862
fix(es/compat): Fix is_setter
in parameters
pass ( #7348 )
...
**Description:**
x-ref: https://vercel.slack.com/archives/C02HY34AKME/p1682667306929829
2023-05-02 02:11:42 +00:00
SWC Bot
11c1f2c7b3
chore: Publish crates
2023-04-30 12:45:00 +00:00
OJ Kwon
91a3fbe460
refactor(plugin/runner): Refine cache location ( #7346 )
2023-04-30 21:43:13 +09:00
Donny/강동윤
afe94b72e5
chore: Publish crates
2023-04-29 22:57:05 +09:00
SWC Bot
4ad18beca3
chore: Publish crates
2023-04-29 13:48:25 +00:00
Donny/강동윤
d061d295ff
fix(es/typescript): Fix typescript strip pass ( #7342 )
...
**Related issue:**
- Reverts #7196 .
- https://github.com/vercel/turbo/issues/4747 .
2023-04-29 22:46:36 +09:00
SWC Bot
767284e27f
chore: Publish crates
2023-04-29 13:28:01 +00:00
magic-akari
985f0cad06
fix(es/parser): Parse decorators after export
( #7340 )
2023-04-29 22:26:13 +09:00
SWC Bot
b80ceaed03
chore: Publish crates
2023-04-29 13:21:14 +00:00
Donny/강동윤
246300ae25
feat(es/minifier): Drop expressions using sequential inliner ( #6936 )
2023-04-29 22:19:00 +09:00
SWC Bot
098b9387c1
chore: Publish crates
2023-04-29 13:00:37 +00:00
Donny/강동윤
d6999ba1ac
fix(plugin/runner): Revert #7341 ( #7344 )
...
**Description:**
This reverts commit 245163a778
.
2023-04-29 21:58:48 +09:00
SWC Bot
2c7f94f1ac
chore: Publish crates
2023-04-29 11:16:12 +00:00
OJ Kwon
245163a778
feat(plugin/runner): Improve caching ( #7341 )
...
**Description:**
Previously disabled cache (storing compiled module in memory) still doesn't work, so falling back to storing raw bytes and create new module each time. This is the same behavior to the wasm build's approach.
Also minor improved caching root to include more information. Previous rustc didn't seem to work unfortunately, so removed but instead using plugin_runner's version.
2023-04-29 11:14:21 +00:00
SWC Bot
e7911ee594
chore: Publish crates
2023-04-26 01:25:19 +00:00
Samuel Eisenhandler
7e99e5fd2c
fix(es/codegen): Emit type arguments for call expressions ( #7335 )
2023-04-26 01:23:13 +00:00
Donny/강동윤
1ecc4385b6
chore: Publish crates
2023-04-25 19:25:16 +09:00
SWC Bot
d67f9bfd75
chore: Publish crates
2023-04-25 10:06:32 +00:00
magic-akari
caee073935
feat(es/module): Add export_interop_annotation
flag ( #7330 )
...
**Related issue:**
- https://github.com/vercel/next.js/issues/48801
2023-04-25 10:04:28 +00:00
Donny/강동윤
897099b970
chore: Publish crates
2023-04-25 09:30:08 +09:00
SWC Bot
5f55e04c4d
chore: Publish crates
2023-04-24 15:01:16 +00:00
Donny/강동윤
603f22de76
test(es): Update tsc test suite ( #7323 )
2023-04-24 14:59:19 +00:00
SWC Bot
923ed13b6a
chore: Publish crates
2023-04-24 09:25:42 +00:00
OJ Kwon
577f81ec40
fix(common): Workaround the Arc
and rkyv
issue ( #7321 )
...
**Description:**
Attempt to workaround #7238 .
Originally I thought this is related with oom or memory layout, then realized actual deserialization error occurs in weird position - it tries to deserialize BytePos (which is obvious type) and it fails. It made me think maybe a property next to the struct layout have some unexpected behavior, notably Arc<String>.
PR applies same workaround as Atom does, and it seems to at least pass swc-coverage-instrument's usecases. May need bit more verification with other plugins to see if we can call this out as reliable workaround.
2023-04-24 09:23:31 +00:00
SWC Bot
51f3840609
chore: Publish crates
2023-04-24 05:25:39 +00:00
Fy
66b5b110bf
fix(es/compat): Transform curried function call with optional chaining ( #7313 )
...
**Related issue:**
- Closes #7312
2023-04-24 05:23:53 +00:00
SWC Bot
5400648de8
chore: Publish crates
2023-04-24 04:17:24 +00:00
David Sherret
0ca05d8b69
fix(es/codegen): Fix codegen of TsModuleDecl
( #7319 )
2023-04-24 04:15:08 +00:00
SWC Bot
caffb9593c
chore: Publish crates
2023-04-24 03:28:05 +00:00
Donny/강동윤
2c441f5c8d
chore: Publish crates
2023-04-21 15:30:05 +09:00
SWC Bot
f2a38e808a
chore: Publish crates
2023-04-21 06:13:37 +00:00
Donny/강동윤
6f81cb9c32
fix(es/parser): Fix handling of in
and out
of typescript ( #7308 )
...
**Related issue:**
- Closes #7305 .
2023-04-21 15:11:18 +09:00
SWC Bot
1812d9ef7f
chore: Publish crates
2023-04-21 04:00:12 +00:00
Donny/강동윤
e7f7b01f59
fix(es): Fix a crash related to source map ( #7307 )
...
**Related issue:**
- Reverts #7229 .
- Closes #7301 .
2023-04-21 03:58:24 +00:00
SWC Bot
c8e6774070
chore: Publish crates
2023-04-20 08:28:29 +00:00
magic-akari
38dfb91ebc
fix(es/helpers): Remove unnecessary parameters in helper_expr!
macro ( #7296 )
...
**Description:**
We have moved to snake_case, so the last parameter of helper_expr is unnecessary.
2023-04-20 08:26:34 +00:00
SWC Bot
af8e158948
chore: Publish crates
2023-04-20 07:35:26 +00:00
Donny/강동윤
9c279b802b
fix(es/modules): Support jsc.baseUrl
without jsc.paths
( #7302 )
...
**Related issue:**
- Closes #1324 .
2023-04-20 07:33:29 +00:00
SWC Bot
35ad9234e9
chore: Publish crates
2023-04-20 02:13:02 +00:00
Donny/강동윤
38495a9835
test(es/compat): Add a test for a wrong issue ( #7300 )
...
**Related issue:**
- Closes #7290 .
2023-04-20 11:10:25 +09:00
SWC Bot
7fd1e93434
chore: Publish crates
2023-04-19 21:54:39 +00:00
Leah
3422923cb0
fix(testing): Fix path normalization on windows for testing diffs ( #7299 )
2023-04-19 21:52:40 +00:00
SWC Bot
ffa76894fd
chore: Publish crates
2023-04-19 14:28:50 +00:00
SWC Bot
095e0ad034
chore: Publish crates
2023-04-19 12:30:15 +00:00
OJ Kwon
39d415cc16
build(cargo): bump up wasmer ( #7294 )
...
**Description:**
Maybe fix? https://github.com/swc-project/swc/issues/7238
https://github.com/wasmerio/wasmer/issues/3764#issuecomment-1514084441
2023-04-19 12:28:31 +00:00
SWC Bot
0e4d764f90
chore: Publish crates
2023-04-19 11:27:00 +00:00
Austaras
7a00f2e954
fix(es/resolver): Hoist parameter in arrow and constructor ( #7292 )
...
**Related issue:**
- Closes #7248 .
---
Co-authored-by: Donny/강동윤 <kdy1997.dev@gmail.com>
2023-04-19 11:25:02 +00:00
SWC Bot
0d4fe74ab5
chore: Publish crates
2023-04-19 07:24:45 +00:00
Donny/강동윤
0aab90c005
fix(es/minifier): Fix a inliner bug related to Script
( #7288 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/7287 .
2023-04-19 07:22:48 +00:00
SWC Bot
b68466c0d9
chore: Publish crates
2023-04-19 06:26:19 +00:00
Donny/강동윤
bc83cb2ecf
perf(preset-env): Update static map ( #7293 )
...
**Description:**
x-ref: https://vercel.slack.com/archives/C02HY34AKME/p1681811874650839
2023-04-19 06:24:23 +00:00
SWC Bot
1c530b8919
chore: Publish crates
2023-04-18 02:46:59 +00:00
Donny/강동윤
248fd374e6
perf(es/react): Don't use regex ( #7284 )
...
**Description:**
It's causing a performance problem in concurrent scenarios.
x-ref: https://linear.app/vercel/issue/WEB-921
x-ref: https://vercel.slack.com/archives/C02HY34AKME/p1681757237489689
2023-04-18 02:45:08 +00:00
Donny/강동윤
e757e65393
chore: Publish crates
2023-04-16 13:23:28 +09:00
SWC Bot
f7355420dd
chore: Publish crates
2023-04-15 14:52:40 +00:00
Donny/강동윤
4c06a56e52
fix(es/minifier): Use UTF16 length for str.length
( #7275 )
...
**Related issue:**
- Closes #7274 .
2023-04-15 14:50:52 +00:00