SWC Bot
a82dd99c45
chore: Publish crates
2023-03-04 09:01:39 +00:00
magic-akari
bb2486c459
fix(es/minifier): Don't create invalid property names ( #7010 )
2023-03-04 17:58:49 +09:00
SWC Bot
28ee1e05fe
chore: Publish crates
2023-03-04 04:17:10 +00:00
Austaras
06cbb9002d
feat(es/minifier): Optimize calls to Boolean
/Number
/String
/Symbol
( #7006 )
2023-03-04 04:14:14 +00:00
SWC Bot
6b48896c4c
chore: Publish crates
2023-03-04 03:35:01 +00:00
Austaras
cfeb088c37
fix(es/minifier): Don't skip expressions with side effects from seq inliner ( #7007 )
2023-03-04 12:32:15 +09:00
SWC Bot
0ade738e43
chore: Publish crates
2023-03-03 02:49:46 +00:00
Daiki Nishikawa
a6471f34c0
feat(es/parser): Add an option to disallow ambiguous jsx ( #6913 )
2023-03-03 02:47:09 +00:00
SWC Bot
c2f0629f57
chore: Publish crates
2023-03-03 02:08:25 +00:00
SWC Bot
a504e2a11d
chore: Publish crates
2023-02-28 08:23:25 +00:00
Donny/강동윤
367ac825f6
refactor(es/parser): Make lexer not generic over Input
( #6993 )
...
**Description:**
Currently, it uses `StringInput` as the input type, but I'll refactor it to use `String` or `Vec<u8>` directly to optimize it further.
**Related issue:**
- https://github.com/swc-project/swc/discussions/6991
2023-02-28 08:20:29 +00:00
SWC Bot
bbb3615af7
chore: Publish crates
2023-02-28 06:42:16 +00:00
Donny/강동윤
37533a23fd
feat(es/parser): Support auto accessors ( #6981 )
2023-02-28 06:39:25 +00:00
SWC Bot
94138c801c
chore: Publish crates
2023-02-28 06:04:29 +00:00
magic-akari
beb38d34a2
feat(es/typescript): Support export type * from "mod"
( #6867 )
2023-02-28 06:01:37 +00:00
Donny/강동윤
dc925f9863
chore: Publish crates
2023-02-28 11:14:03 +09:00
SWC Bot
460a5cb897
chore: Publish crates
2023-02-27 02:40:15 +00:00
SWC Bot
2525a844da
chore: Publish crates
2023-02-23 08:49:08 +00:00
Gengkun
cc1d9bd567
fix(css/utils): Fix minification of class names with whitespace ( #6983 )
2023-02-23 08:46:24 +00:00
SWC Bot
c46c4f518f
chore: Publish crates
2023-02-23 07:58:41 +00:00
Donny/강동윤
b887b30092
test(es/tsc): Update tsc test suite ( #6982 )
...
**Description:**
This is required for https://github.com/swc-project/swc/pull/6981 and https://github.com/swc-project/swc/pull/6950
2023-02-23 07:55:58 +00:00
SWC Bot
447c1dad93
chore: Publish crates
2023-02-23 01:39:46 +00:00
magic-akari
703b340d39
fix(es/decorator): Preserve evaluation order ( #6972 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6951 .
2023-02-23 01:37:06 +00:00
SWC Bot
9e05f4c2d2
chore: Publish crates
2023-02-22 14:20:23 +00:00
IWANABETHATGUY
f1e7a2a9cc
chore(es/parser): Reduce pre-allocation to reduce memory usage ( #6979 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6966 .
2023-02-22 14:17:45 +00:00
SWC Bot
6496796c59
chore: Publish crates
2023-02-22 06:52:59 +00:00
Donny/강동윤
f12bfd1e55
chore: Publish crates
2023-02-21 16:10:52 +09:00
SWC Bot
e42b60b65c
chore: Publish crates
2023-02-21 06:25:11 +00:00
magic-akari
a27ffd2242
feat(es/minifier): Drop unused import bindings ( #6967 )
2023-02-21 06:22:25 +00:00
SWC Bot
2eb4c1cabd
chore: Publish crates
2023-02-21 05:38:59 +00:00
Hikaru Terazono (3c1u)
4771aa206a
fix(css/modules): Fix CSS animation
on CSS Modules ( #6969 )
2023-02-21 14:36:22 +09:00
SWC Bot
786f8180ad
chore: Publish crates
2023-02-20 05:31:02 +00:00
magic-akari
1dfadb8790
fix(es/minifier): Fix optimization of expressions in numeric context ( #6965 )
2023-02-20 05:28:28 +00:00
SWC Bot
89bbadbda6
chore: Publish crates
2023-02-19 14:53:16 +00:00
Donny/강동윤
e946c43f4e
fix(es/resolver): Use type context for export =
if it's unresolved ( #6963 )
...
**Related issue:**
- https://github.com/dudykr/stc/issues/717 .
2023-02-19 23:50:19 +09:00
SWC Bot
b9398ce2d9
chore: Publish crates
2023-02-19 14:20:55 +00:00
magic-akari
9382bda786
fix(es/minifier): Fix toFixed
, toPrecision
, toExponential
and toString
of Number ( #6960 )
2023-02-19 23:18:14 +09:00
SWC Bot
6f18f23326
chore: Publish crates
2023-02-18 11:50:22 +00:00
SWC Bot
63c5c7bbb0
chore: Publish crates
2023-02-16 05:05:34 +00:00
Laurent Gaucheron
542bb62ef7
fix(bundler): Don't panic while finding exports ( #6947 )
2023-02-16 14:00:49 +09:00
SWC Bot
6d7bf02e96
chore: Publish crates
2023-02-15 04:34:08 +00:00
Donny/강동윤
14454c9dbd
fix(es/react): Don't panic on key
without a value ( #6945 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6939 .
2023-02-15 04:31:02 +00:00
SWC Bot
4c6775646b
chore: Publish crates
2023-02-14 04:50:23 +00:00
SWC Bot
8c5a53d0d5
chore: Publish crates
2023-02-14 03:16:15 +00:00
LongYinan
0771418dd0
chore(swc_nodejs_common): remove swc_node_base from swc_nodejs_common ( #6940 )
...
- Ref: https://github.com/vercel/turbo/pull/3772
2023-02-14 03:13:36 +00:00
SWC Bot
f1f5a19e61
chore: Publish crates
2023-02-12 21:38:45 +00:00
Donny/강동윤
a9b25aaf4a
fix(es/react): Fix handling of whitespaces ( #6935 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6931 .
2023-02-12 21:35:55 +00:00
SWC Bot
5a598140c1
chore: Publish crates
2023-02-11 16:29:50 +00:00
Donny/강동윤
1ec161a0f1
fix(es/module): Fix jsc.paths
on Windows ( #6930 )
...
**Related issue:**
- Reverts https://github.com/swc-project/swc/pull/6716 .
- Closes https://github.com/swc-project/swc/issues/6782 .
2023-02-11 16:27:17 +00:00
SWC Bot
e332dffb58
chore: Publish crates
2023-02-10 18:32:51 +00:00
Donny/강동윤
0559f2c2b4
chore: Publish crates
2023-02-10 14:02:48 +09:00
SWC Bot
e600586925
chore: Publish crates
2023-02-10 03:56:01 +00:00
Donny/강동윤
ebc65c7dcb
fix(es/typescript): Fix handling of non-uppercase JSX elements ( #6928 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6923 .
2023-02-10 12:53:11 +09:00
SWC Bot
b9212cfee0
chore: Publish crates
2023-02-10 02:51:53 +00:00
SWC Bot
cade201a1f
chore: Publish crates
2023-02-10 02:30:18 +00:00
OJ Kwon
75376cd65c
chore: Bump swc_css_* ( #6924 )
2023-02-10 11:27:20 +09:00
SWC Bot
29fee38224
chore: Publish crates
2023-02-09 05:11:07 +00:00
Donny/강동윤
85a8defc37
fix(es/preset-env): Fix default target ( #6921 )
...
**Description:**
Previously the default value of `targets` was `""`, which is not deterministic.
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6888 .
2023-02-09 05:08:41 +00:00
SWC Bot
fe095e9dc1
chore: Publish crates
2023-02-09 03:10:10 +00:00
Donny/강동윤
725d3fb645
fix(es/minifier): Don't skip shorthand properties from sequential inliner ( #6918 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6914 .
2023-02-09 03:07:31 +00:00
Donny/강동윤
932d5a5302
chore: Publish crates
2023-02-08 16:51:05 +09:00
SWC Bot
b72ee503e4
chore: Publish crates
2023-02-08 07:48:41 +00:00
SWC Bot
63216ccf3f
chore: Publish crates
2023-02-08 06:47:21 +00:00
Donny/강동윤
d18027cf9b
test(es/module): Add a test for jsc.paths
on windows ( #6915 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/5165 .
2023-02-08 06:44:22 +00:00
SWC Bot
f7f18eded3
chore: Publish crates
2023-02-08 05:48:53 +00:00
SWC Bot
a566f9c999
chore: Publish crates
2023-02-08 05:17:01 +00:00
Donny/강동윤
4c5d5a6fca
fix(es/parser): Don't use stacker
for armv7 ( #6916 )
2023-02-08 05:14:41 +00:00
SWC Bot
4be6c33687
chore: Publish crates
2023-02-08 04:37:20 +00:00
Ah
f85ea9cb57
fix(css/modules): Fix interop of &
and :global
( #6900 )
2023-02-08 04:34:38 +00:00
Donny/강동윤
c293c14aaa
chore: Publish crates
2023-02-08 12:04:02 +09:00
SWC Bot
6112471d25
chore: Publish crates
2023-02-08 02:13:29 +00:00
Donny/강동윤
951dafbc1a
fix(es/minifier): Don't break ternary with assignment in test ( #6906 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6903 .
2023-02-08 02:10:44 +00:00
SWC Bot
7f7e21b687
chore: Publish crates
2023-02-07 16:12:00 +00:00
Alex Vasilev
85fffdad02
fix(es/module): Fix SystemJS imports ( #6879 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/5922 .
2023-02-07 16:07:46 +00:00
SWC Bot
74070935a9
chore: Publish crates
2023-02-07 15:20:28 +00:00
Daiki Nishikawa
76bc8a2974
feat(bindings/cli): Support for *.mts/*.cts files ( #6909 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/4679 .
2023-02-07 15:18:10 +00:00
SWC Bot
e65699c755
chore: Publish crates
2023-02-07 14:35:38 +00:00
Donny/강동윤
f36d945a33
fix(es/parser): Fix stack overflow due to deeply nested if ( #6910 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6813 .
2023-02-07 14:33:13 +00:00
SWC Bot
bd0072511b
chore: Publish crates
2023-02-07 08:09:02 +00:00
Donny/강동윤
ee3a1071a5
fix(es/typescript): Ignore jsx element names ( #6911 )
...
**Related issue:**
- https://github.com/vercel/next.js/issues/45561 .
2023-02-07 08:06:37 +00:00
SWC Bot
58b74ffbe2
chore: Publish crates
2023-02-07 06:24:58 +00:00
SWC Bot
113b85ee40
chore: Publish crates
2023-02-07 05:17:06 +00:00
Donny/강동윤
432dca647b
fix(es/minifier): Respect span hygiene from expr simplifier ( #6899 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6896 .
2023-02-07 05:14:19 +00:00
SWC Bot
af175fde8b
chore: Publish crates
2023-02-07 03:46:20 +00:00
SWC Bot
33093877c1
chore: Publish crates
2023-02-05 21:38:41 +00:00
Jonathan Rudenberg
d993c4def6
feat(bindings/cli): Add --config
( #6835 )
2023-02-05 21:35:48 +00:00
SWC Bot
f2333e4ccf
chore: Publish crates
2023-02-05 19:50:46 +00:00
SWC Bot
c223113338
chore: Publish crates
2023-02-01 10:34:44 +00:00
SWC Bot
18af9c3a27
chore: Publish crates
2023-02-01 06:51:38 +00:00
Donny/강동윤
861d87cae6
fix(es/resolver): Resolve parameters correctly ( #6890 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/5622 .
2023-02-01 15:49:08 +09:00
Donny/강동윤
ab02c0a07e
chore: Publish crates
2023-02-01 09:37:56 +09:00
SWC Bot
61397267bb
chore: Publish crates
2023-01-31 15:04:52 +00:00
Donny/강동윤
e79d46697c
test(es/compat): Add a test for a fixed issue ( #6887 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6886 .
2023-01-31 15:01:57 +00:00
SWC Bot
5160378f53
chore: Publish crates
2023-01-31 06:27:05 +00:00
Donny/강동윤
57781e90d3
fix(es/compat): Make optional chaining pass less permissive ( #6885 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6878 .
2023-01-31 06:24:23 +00:00
SWC Bot
f89d3d688c
chore: Publish crates
2023-01-31 05:47:59 +00:00
Donny/강동윤
d6a24a28e8
build(cargo): Drop dependencies on retain_mut
( #6884 )
2023-01-31 05:45:37 +00:00
SWC Bot
cdfaa8e292
chore: Publish crates
2023-01-31 03:24:17 +00:00
Donny/강동윤
9301703311
fix(es): Remove useless message ( #6882 )
2023-01-31 03:21:32 +00:00
Donny/강동윤
1bf2b2ddbf
chore: Publish crates
2023-01-30 22:35:40 +09:00
SWC Bot
3e8d80a324
chore: Publish crates
2023-01-30 11:17:16 +00:00
Donny/강동윤
d8088646df
fix(es/compat): Fix optional chaining pass ( #6875 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6762 .
2023-01-30 11:14:53 +00:00
SWC Bot
edc432713e
chore: Publish crates
2023-01-29 15:33:29 +00:00
Daiki Nishikawa
6b7249dcde
feat(es/loader): Support node:
prefix from NodeModulesResolver
( #6868 )
2023-01-29 15:31:13 +00:00
SWC Bot
0bb4dc2c3d
chore: Publish crates
2023-01-29 14:56:26 +00:00
HeYunfei
508267dccf
fix(visit): Fix detection of Option<Vec<T>>
( #6872 )
2023-01-29 14:54:08 +00:00
Donny/강동윤
b8fcf3bc62
chore: Publish crates
2023-01-29 22:44:56 +09:00
SWC Bot
2836fb207b
chore: Publish crates
2023-01-29 13:30:41 +00:00
Donny/강동윤
cb3901cb5e
chore: Publish crates
2023-01-29 03:35:48 +09:00
SWC Bot
3babace12d
chore: Publish crates
2023-01-28 18:34:39 +00:00
SWC Bot
1b56b40fda
chore: Publish crates
2023-01-28 17:21:30 +00:00
Austaras
c0e72ef64a
fix(es/minifier): Track reassign in parent scope ( #6865 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6864 .
2023-01-28 17:19:19 +00:00
SWC Bot
33dab56853
chore: Publish crates
2023-01-27 13:00:49 +00:00
Alex Vasilev
39c75fdcce
fix(es/module): Fix handling of this
for systemjs
( #6857 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6784 .
2023-01-27 12:58:22 +00:00
SWC Bot
5a5a7d70e4
chore: Publish crates
2023-01-27 06:59:44 +00:00
Donny/강동윤
60d9403073
fix(es/parser): Fix parsing of generics ( #6859 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6851 .
2023-01-27 06:57:19 +00:00
SWC Bot
586783a7ac
chore: Publish crates
2023-01-27 05:38:19 +00:00
Donny/강동윤
d1687d8e01
feat(es/minifier): Improve compatibility of arrows
with terser
( #6862 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6123 .
2023-01-27 14:36:12 +09:00
SWC Bot
49d9237e64
chore: Publish crates
2023-01-27 04:47:07 +00:00
Donny/강동윤
45cdfed6c8
chore(ci): FIx CI ( #6861 )
2023-01-27 04:44:58 +00:00
Donny/강동윤
420a67ac2b
chore: Publish crates
2023-01-26 17:22:40 +09:00
Donny/강동윤
7147cb3e2a
chore: Publish crates
2023-01-26 12:27:54 +09:00
SWC Bot
dbb3f362aa
chore: Publish crates
2023-01-26 03:09:22 +00:00
SWC Bot
8fc1b651b1
chore: Publish crates
2023-01-26 02:11:53 +00:00
Donny/강동윤
99d48e305e
fix(plugin): Make span_to_source
use dedicated function ( #6853 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6852 .
- Closes https://github.com/swc-project/swc/issues/6404 .
2023-01-26 02:09:36 +00:00
SWC Bot
28be71dfaf
chore: Publish crates
2023-01-26 01:19:53 +00:00
Austaras
55225cb994
refactor(es/minifier): Merge cond_init
with reassigned
( #6850 )
...
**Description:**
And optimize the following situation
```js
export function genElement(el, state) {
if ('slot' === el.tag) return el1 = el, genChildren(el1);
if (el.component) {
var el1
return 999;
}
}
```
which rarely happens in hand written JS, but is often generated by swc merge variable pass.
2023-01-26 10:17:33 +09:00
Donny/강동윤
1bf9b3777e
chore: Publish crates
2023-01-24 16:05:45 +09:00
SWC Bot
7ee39c73e1
chore: Publish crates
2023-01-24 07:05:16 +00:00
SWC Bot
30b8cc612e
chore: Publish crates
2023-01-24 06:18:52 +00:00
HeYunfei
58208ef8ae
perf(es/minifier): Make pure function check O(1)
( #6840 )
2023-01-24 06:16:23 +00:00
SWC Bot
05724e5122
chore: Publish crates
2023-01-23 10:16:00 +00:00
Austaras
2fcab36418
refactor(es/preset-env): Use a const fn instead of a macro ( #6844 )
2023-01-23 10:13:42 +00:00
SWC Bot
1d81137592
chore: Publish crates
2023-01-20 08:52:56 +00:00
Donny/강동윤
21e14787c5
fix(es/minifier): Don't inline into await
from sequential inliner ( #6839 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6837 .
2023-01-20 08:50:51 +00:00
SWC Bot
8863e31446
chore: Publish crates
2023-01-20 08:11:11 +00:00
Donny/강동윤
df702614e1
fix(es/codegen): Fix codegen of string literals with \x000
( #6838 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6836 .
2023-01-20 08:08:58 +00:00
SWC Bot
8194c65953
chore: Publish crates
2023-01-18 02:19:16 +00:00
Alex Dixon
7205543d5f
refactor(es/typescript): Remove unused code ( #6830 )
2023-01-18 02:16:43 +00:00
SWC Bot
09b3e72861
chore: Publish crates
2023-01-17 06:58:46 +00:00
Donny/강동윤
6ba726ba28
chore: Publish crates
2023-01-17 11:56:28 +09:00
SWC Bot
6f77544a10
chore: Publish crates
2023-01-17 02:52:10 +00:00
SWC Bot
c3607ba6eb
chore: Publish crates
2023-01-16 16:09:51 +00:00
RiESAEX
ad8d043f1d
feat(es/helper): Use require
to load polyfills and helpers in Script ( #6778 )
2023-01-16 16:07:40 +00:00
SWC Bot
b1f3eb74df
chore: Publish crates
2023-01-16 15:26:01 +00:00
westhide
e9fdac216c
fix(es/codegen): Skip space if jsx attrs is empty ( #6823 )
2023-01-16 15:23:28 +00:00
SWC Bot
4a75eb0157
chore: Publish crates
2023-01-16 06:59:39 +00:00
Donny/강동윤
ebce18b221
fix(es/renamer): Handle rest params correctly ( #6821 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6819 .
2023-01-16 06:57:16 +00:00
SWC Bot
179a5f8a92
chore: Publish crates
2023-01-16 04:53:53 +00:00
Donny/강동윤
82bd5c2041
feat(es/renamer): Rename synthesized identifiers even on eval
( #6818 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/5068 .
2023-01-16 04:51:47 +00:00
SWC Bot
a5707ae7c1
chore: Publish crates
2023-01-15 06:45:26 +00:00
Donny/강동윤
ff78b8f7e0
feat(es/ast): Add EsNext
to EsVersion
( #6816 )
2023-01-15 15:43:10 +09:00
SWC Bot
4ea0e20ded
chore: Publish crates
2023-01-15 00:20:53 +00:00
SWC Bot
767f50040b
chore: Publish crates
2023-01-14 09:00:21 +00:00
Alexander Akait
43e75194e5
feat(css/parser): Normalize at-rules ( #6705 )
2023-01-14 08:58:24 +00:00
SWC Bot
47cc6446d4
chore: Publish crates
2023-01-13 07:32:44 +00:00
Donny/강동윤
e7ea054c63
test(es): Enable execution tests for fixed issues ( #6805 )
2023-01-13 07:30:21 +00:00
SWC Bot
0bc0a0d274
chore: Publish crates
2023-01-13 06:57:24 +00:00
Donny/강동윤
8f683e3f77
feat(es/minifier): Remove noop spreads ( #6803 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6788 .
2023-01-13 06:55:04 +00:00
SWC Bot
b5adb7b842
chore: Publish crates
2023-01-13 05:42:09 +00:00
Donny/강동윤
a299fd0418
test(es/minifier): Add a test for an invalid issue ( #6802 )
...
**Related issue:**
- https://github.com/vercel/next.js/discussions/30237#discussioncomment-4674405
2023-01-13 05:39:22 +00:00
SWC Bot
b27793f579
chore: Publish crates
2023-01-13 05:02:46 +00:00
Donny/강동윤
631dd7872b
feat(es/renamer): Support safari10
from the name mangler ( #6801 )
2023-01-13 05:00:13 +00:00
SWC Bot
75bf8397ba
chore: Publish crates
2023-01-12 11:42:47 +00:00
Donny/강동윤
224eff91eb
feat(es/quote): Allow using Str
as a var ( #6797 )
2023-01-12 11:40:26 +00:00
SWC Bot
be0af3ff13
chore: Publish crates
2023-01-12 11:04:17 +00:00
Donny/강동윤
b29aa5b5a0
test(es/preset-env): Add a test for a wrong issue ( #6794 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6460 .
2023-01-12 11:01:25 +00:00
SWC Bot
ba910306ad
chore: Publish crates
2023-01-12 09:22:29 +00:00
Donny/강동윤
07676d5515
fix(es/compat): Ignore this
in nested scopes in classes
pass ( #6796 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6506 .
2023-01-12 09:19:40 +00:00
SWC Bot
2efcbdd2b4
chore: Publish crates
2023-01-12 07:31:36 +00:00
Donny/강동윤
c14540905f
fix(es/transform): Apply hygiene
and resolver
if minify is specified ( #6793 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6791 .
2023-01-12 07:29:28 +00:00
SWC Bot
06e7db9f06
chore: Publish crates
2023-01-12 06:56:43 +00:00
Donny/강동윤
7dc5ccb0fc
test(es/compat): Add a test to verify parameters passs ( #6792 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6790 .
2023-01-12 15:54:36 +09:00
Donny/강동윤
5496379454
chore: Publish crates
2023-01-11 18:36:16 +09:00
SWC Bot
d9b22b8bf7
chore: Publish crates
2023-01-11 08:43:06 +00:00
SWC Bot
1431c735a9
chore: Publish crates
2023-01-11 07:44:21 +00:00
Donny/강동윤
bbfa97a475
fix(es/decorator): Fix type detection for template literal types ( #6786 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6682 .
2023-01-11 07:42:09 +00:00
SWC Bot
eddf8fd1bb
chore: Publish crates
2023-01-11 07:06:58 +00:00
Donny/강동윤
06770cff04
fix(es/minifier): Make AST compressor respect toplevel
( #6775 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/4386 .
2023-01-11 07:04:20 +00:00
SWC Bot
267d256b5b
chore: Publish crates
2023-01-11 06:04:36 +00:00
Donny/강동윤
336b1d8b4d
fix(es/minifier): Don't inline conditionally initialized vars ( #6751 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6750 .
- Closes https://github.com/swc-project/swc/issues/6780 .
2023-01-11 06:01:56 +00:00
SWC Bot
c695249b2a
chore: Publish crates
2023-01-11 05:09:17 +00:00
Donny/강동윤
0ef84e1c00
test(es/module): Add a test for invalid issue ( #6785 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6779 .
2023-01-11 05:06:45 +00:00
SWC Bot
cd06479a43
chore: Publish crates
2023-01-11 03:00:59 +00:00
HeYunfei
ff8facef64
fix(es/parser): Allow parsing import.meta
as an expression ( #6783 )
2023-01-11 02:58:25 +00:00
SWC Bot
70c3126771
chore: Publish crates
2023-01-10 10:21:15 +00:00
Donny/강동윤
ae3cfa7d2d
fix(es): Remove useless context ( #6777 )
2023-01-10 10:19:01 +00:00
SWC Bot
6f1e08fa3c
chore: Publish crates
2023-01-10 06:45:17 +00:00
Donny/강동윤
ec7e913815
fix(es/minifier): Make name mangler respect toplevel
( #6774 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6418 .
2023-01-10 06:42:49 +00:00
SWC Bot
52dada97ff
chore: Publish crates
2023-01-10 06:03:34 +00:00
Donny/강동윤
3f0f664c48
fix(es/codegen): Skip lo
of a program if body is not empty ( #6773 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6767 .
2023-01-10 06:01:14 +00:00
SWC Bot
478b1fe458
chore: Publish crates
2023-01-10 05:10:48 +00:00
magic-akari
019cf37199
feat(es/typescript): Support const modifier on type parameters ( #6672 )
...
**Related issue:**
- https://github.com/microsoft/TypeScript/pull/51865 .
2023-01-10 05:08:29 +00:00
SWC Bot
b102504eb9
chore: Publish crates
2023-01-10 03:30:52 +00:00
Donny/강동윤
6d365de9e2
chore(ci): Fix CI action ( #6772 )
2023-01-10 03:28:07 +00:00
SWC Bot
ca64ab0906
chore: Publish crates
2023-01-09 11:00:40 +00:00
magic-akari
1d147602c0
fix(es/helpers): Make _classPrivateFieldLooseBase
return receiver ( #6770 )
2023-01-09 10:58:29 +00:00
SWC Bot
a145bb5776
chore: Publish crates
2023-01-09 06:27:08 +00:00
Donny/강동윤
6c126da1d4
test(es): Add a test for a fixed source map issue ( #6768 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6244 .
2023-01-09 06:25:03 +00:00
SWC Bot
a225efe363
chore: Publish crates
2023-01-08 04:59:27 +00:00
Justin Ridgewell
2b503c16d5
fix(es/codegen): Fix LineCol calculation of printed files ( #6763 )
...
**Description:**
There were several issues with the way we updated the current `LineCol` position during the printing of the generated file:
- We used `chars` and `char_indices` (UTF-32) instead of `encode_utf16` (UTF-16) chars.
- JS uses UCS-2 (basically UTF-16) for its strings, and source maps default to that implicitly.
- `\r` was incorrectly handled
- it didn't add a `line_start`; only `\n` did
- `\r\n` was incorrectly handled
- It was trying to let the `\n` path handle the `line_start`, but it called
`chars.next()` which ate the `\n` char.
I also took the opportunity to avoid the `Vec` allocations and reduced some code duplication.
See the
[before](https://evanw.github.io/source-map-visualization/#ODEzAC8qKgogKiBmb28KICogQHBhcmFtIGRhdGEgZm9vCiAqIEByZXR1cm5zIGZvbwogKi8gZXhwb3J0IGNvbnN0IGZpeHVwUmlza0NvbmZpZ0RhdGEgPSAoZGF0YSk9PnsKICAgIGlmICh4KSB7CiAgICAgICAgcmV0dXJuIDEyMzsKICAgIH0gZWxzZSB7CiAgICAgICAgcmV0dXJuIDQ1NjsKICAgIH0KfTsKCi8vIyBzb3VyY2VNYXBwaW5nVVJMPWRhdGE6YXBwbGljYXRpb24vanNvbjtiYXNlNjQsZXlKMlpYSnphVzl1SWpvekxDSnpiM1Z5WTJWeklqcGJJbWx1Y0hWMExuUnpJbDBzSW5OdmRYSmpaWE5EYjI1MFpXNTBJanBiSWk4cUtseHlYRzRnS2lCbWIyOWNjbHh1SUNvZ1FIQmhjbUZ0SUdSaGRHRWdabTl2WEhKY2JpQXFJRUJ5WlhSMWNtNXpJR1p2YjF4eVhHNGdLaTljY2x4dVpYaHdiM0owSUdOdmJuTjBJR1pwZUhWd1VtbHphME52Ym1acFowUmhkR0VnUFNBb1pHRjBZVG9nWVc1NUtUb2dkSGx3WlhNdVVtbHphME52Ym1acFoxUjVjR1VnUFQ0Z2UxeHlYRzRnSUdsbUlDaDRLU0I3WEhKY2JpQWdJQ0J5WlhSMWNtNGdNVEl6TzF4eVhHNGdJSDBnWld4elpTQjdYSEpjYmlBZ0lDQnlaWFIxY200Z05EVTJPMXh5WEc0Z0lIMWNjbHh1ZlRzaVhTd2libUZ0WlhNaU9sc2labWw0ZFhCU2FYTnJRMjl1Wm1sblJHRjBZU0lzSW1SaGRHRWlMQ0o0SWwwc0ltMWhjSEJwYm1keklqb2lRVUZCUVN4dFJFRkpReXhIUVVORUxFOUJRVThzVFVGQlRVRXNjMEpCUVhOQ0xFTkJRVU5ETEU5QlFXOURPMGxCUTNSRkxFbEJRVWxET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clxuICAgIHJldHVybiA0NTY7XHJcbiAgfVxyXG59OyJdLCJuYW1lcyI6WyJmaXh1cFJpc2tDb25maWdEYXRhIiwiZGF0YSIsIngiXSwibWFwcGluZ3MiOiJBQUFBOzs7O0NBSUMsR0FDRCxPQUFPLElBQU1BLHNCQUFzQixTQUFDQyxNQUFvQztJQUN0RSxJQUFJQyxHQUFHO1FBQ0wsT0FBTztJQUNULE9BQU87UUFDTCxPQUFPO0lBQ1QsQ0FBQztBQUNILEVBQUUifQ== )
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6694 .
2023-01-08 13:57:26 +09:00
SWC Bot
fb6770f649
chore: Publish crates
2023-01-06 08:17:26 +00:00
HeYunfei
8a6a1cbcf1
feat(es/minifier): Handle boolean in Evaluator
( #6756 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/5953 .
2023-01-06 08:15:07 +00:00
Donny/강동윤
48902b60d3
chore: Publish crates
2023-01-06 16:41:16 +09:00
SWC Bot
1161360d54
chore: Publish crates
2023-01-06 03:49:20 +00:00
Donny/강동윤
26a0c13589
fix(common): Mark \r
as a line ending ( #6752 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6694 .
2023-01-06 03:47:16 +00:00
SWC Bot
ec8497b42c
chore: Publish crates
2023-01-06 03:16:51 +00:00
HeYunfei
a1ccc8afdf
feat(es/minifier): Make name mangler understand block scoping ( #6670 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/5090 .
- Closes https://github.com/swc-project/swc/issues/5766 .
2023-01-06 03:14:10 +00:00
Donny/강동윤
e9f99c4fe7
chore: Publish crates
2023-01-06 10:41:41 +09:00
SWC Bot
e5ea18b62b
chore: Publish crates
2023-01-05 23:46:00 +00:00
Donny/강동윤
f299101820
chore: Publish crates
2023-01-05 19:55:20 +09:00
SWC Bot
1f5c44ea70
chore: Publish crates
2023-01-05 10:09:49 +00:00
Donny/강동윤
b46815a684
fix(es): Fix wasm ( #6755 )
2023-01-05 10:07:45 +00:00
SWC Bot
3b034d597b
chore: Publish crates
2023-01-05 05:18:09 +00:00
SWC Bot
918a01bf5c
chore: Publish crates
2023-01-04 14:19:54 +00:00
HeYunfei
36b26d3496
fix(es/react): Force refresh if code contains @refresh reset
( #6749 )
2023-01-04 14:17:01 +00:00
SWC Bot
790c478a7a
chore: Publish crates
2023-01-04 07:29:33 +00:00
Donny/강동윤
65a0d3a310
fix(es/parser): Fix priority of >>>
( #6748 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6739 .
2023-01-04 07:27:08 +00:00
SWC Bot
d7081cc8a6
chore: Publish crates
2023-01-04 05:17:53 +00:00
Donny/강동윤
72fb606eb2
feat(es/jest): Support chaining of jest function calls ( #6747 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6540 .
2023-01-04 05:15:21 +00:00
SWC Bot
1638105865
chore: Publish crates
2023-01-04 04:33:32 +00:00
Donny/강동윤
88d40e8ab8
fix(es/minifier): Fix usage counter to fix infinite loop ( #6744 )
...
**Description:**
We skip non-computed property names while checking if we can inline an expression.
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6729 .
2023-01-04 04:31:12 +00:00
Donny/강동윤
62c0d7291a
chore: Publish crates
2023-01-04 12:13:55 +09:00
SWC Bot
9bdbe9dc9b
chore: Publish crates
2023-01-03 10:24:43 +00:00
RiESAEX
79afcb5d81
doc(es): Fix example ( #6743 )
2023-01-03 10:22:44 +00:00
SWC Bot
30471796c9
chore: Publish crates
2023-01-03 09:47:06 +00:00
Donny/강동윤
206c0dbebe
fix(es/compat): Fix syntax context of async-to-generator
( #6741 )
...
**Description:**
Previously, the `async-to-generator` produced invalid AST, in the aspect of span hygiene.
[Playground](https://play.swc.rs/?version=1.3.24&code=H4sIAAAAAAAAAz1MbQqAIBT77yn2UyG6gNQJuoSZRCAa7xkk4d1TicZgH7C5%2B4yUYGPgBE7ZuyWazREmSIVpxiMAcumi0C3ANZxyvQ6%2Fqa8CehxjaGNpOAcLaWjn%2F6KhKN1dGaoULSpfHPTdxn8AAAA%3D&config=H4sIAAAAAAAAA0WOSwrDMAxE76K1F22hXfgE3fQQxlWCi39ICsQY3z12cMlOjObNTIUfW9AVsiFGGheXKGYHDVIysiWXBRQId2kxnrEpwF2QovFv9BmJQQtt2D2GVpROIj9u92enfEqMk1MQXHRLGR02hUzIfL1MXP3f2XpFSN9tCPWccWa%2BoF0Zk3P8mcYxoR3Kj7IYzwAAAA%3D%3D ).
It generate two bindings for `args` so it's invalid.
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6730 .
2023-01-03 09:45:03 +00:00
SWC Bot
1602f66fe6
chore: Publish crates
2023-01-03 03:47:48 +00:00
RiESAEX
98da6444b6
perf(es/preset-env): Use VisitMut
instead of Fold
for polyfill ( #6734 )
2023-01-03 03:45:25 +00:00
SWC Bot
2e32faaa3c
chore: Publish crates
2023-01-03 03:14:24 +00:00
HeYunfei
b5d31cc2da
fix(es/utils): Fix detection of hoisting ( #6738 )
2023-01-03 03:12:01 +00:00
SWC Bot
0a1e30a4f8
chore: Publish crates
2022-12-30 06:34:07 +00:00
SWC Bot
0a652096ae
chore: Publish crates
2022-12-27 12:57:51 +00:00
Alexander Akait
1722428909
feat(css/prefixer): Support clamp
( #6695 )
2022-12-27 12:55:46 +00:00
SWC Bot
d72a31f990
chore: Publish crates
2022-12-27 12:24:41 +00:00
Alexander Akait
8af627d5c4
feat(css/parser): Normalize urange ( #6704 )
2022-12-27 12:22:46 +00:00
SWC Bot
35b72b59c8
chore: Publish crates
2022-12-27 07:43:30 +00:00
SWC Bot
bfb2ffee0c
chore: Publish crates
2022-12-27 01:02:01 +00:00
realtimetodie
b451fa9e88
fix(es): Remove import statement canonicalization ( #6716 )
2022-12-27 00:59:54 +00:00
Donny/강동윤
d506c96805
fix(preset-env): Update data ( #6719 )
2022-12-26 04:46:08 +00:00
SWC Bot
22973cbbf2
chore: Publish crates
2022-12-23 05:07:21 +00:00
SWC Bot
7fcc978748
chore: Publish crates
2022-12-22 01:39:10 +00:00
Alexander Akait
ebebd60875
refactor(css/codegen): Do not use raw
( #6674 )
2022-12-22 01:36:36 +00:00
SWC Bot
ef1d966b57
chore: Publish crates
2022-12-21 14:03:20 +00:00
Alexander Akait
27a8b7e50b
feat(css/prefixer): Support page break ( #6693 )
2022-12-21 14:00:59 +00:00
SWC Bot
e89f7856f7
chore: Publish crates
2022-12-21 09:37:10 +00:00
Donny/강동윤
58700f2bec
fix(es): Preserve license comments by default ( #6703 )
...
**Related issue:**
- Closes https://github.com/swc-project/swc/issues/6677 .
2022-12-21 09:34:40 +00:00
SWC Bot
af8a3a6b9d
chore: Publish crates
2022-12-21 07:40:45 +00:00
SWC Bot
61245739ea
chore: Publish crates
2022-12-21 03:03:05 +00:00
Alexander Akait
1c7f003779
feat(css/prefixer): Support overflow
( #6678 )
2022-12-21 03:00:53 +00:00