Commit Graph

1779 Commits

Author SHA1 Message Date
Alexander Akait
d8ddb2fb99
fix(css/parser): Fix parsing of escaped characters (#2700) 2021-11-10 12:49:32 +00:00
Donny
3adeb6bf30 chore: Publish crates 2021-11-10 20:57:43 +09:00
Donny/강동윤
df635c9e6d
fix(es/minifier): Fix minifier (#2711)
swc_ecma_minifier:
 - Respect `inline_prevented`.
 - Mark the LHS of an assignment pattern property as a pattern. (https://github.com/vercel/next.js/issues/30498)
2021-11-10 20:56:50 +09:00
Sriram Thiagarajan
cb689565d5
chore: Update README.md (#2693) 2021-11-10 11:09:20 +00:00
Donny/강동윤
2b2f6955f2
refactor: Flatten ecmascript (#2708) 2021-11-10 19:00:54 +09:00
Donny/강동윤
a90fae5696
fix(swc): Fix tests (#2707) 2021-11-10 18:08:45 +09:00
Donny
4863bee163 chore: Publish crates 2021-11-10 17:35:07 +09:00
OJ Kwon
691e5e581c
fix(es/transforms/common_js): Allow reassignment to functions exported as default (#2705)
swc_ecma_transforms_module:
 - Mark a function exported using `default` as reassignable target.
2021-11-10 17:33:44 +09:00
Donny/강동윤
4f70ee6d98
refactor: Flatten more packages (#2706) 2021-11-10 16:39:01 +09:00
Donny
158136fae9 chore: Publish crates 2021-11-10 16:16:19 +09:00
Donny/강동윤
8edd72ed73
fix(es/transforms/compat): Use _createSuper for super classes (#2699)
swc_ecma_transforms_base:
 - Add `_createSuper` helper.
 - Add `_isNativeReflectConstruct` helper.

swc_ecma_transforms_compat:
 - `classes`: Apply `_createSuper` to the super classes.
2021-11-10 16:15:03 +09:00
Donny
2be8559e35 chore: Publish crates 2021-11-10 13:58:42 +09:00
OJ Kwon
824fa24852
perf(es/transforms/compat): Migrate to VisitMut (#2696)
swc_ecma_transforms_compat:
 - `async_to_generator`: Migrate helper to `VisitMut`.
2021-11-10 13:57:56 +09:00
Donny/강동윤
687305f280
refactor: Flatten crates (#2697) 2021-11-09 20:42:49 +09:00
Donny/강동윤
bf0007bec0
feat(rplugin): Implement general AST processing plugin system (#2671)
swc_common:
 - Implement `StableAbi` for `BytePos`.
 - Implement `StableAbi` for `Span`.

rplugin:
 - Add `StableAst`.

swc_plugin_api:
 - Drop unused dependencies.

swc_ecma_plugin_ast:
 - Initialize crate.
2021-11-09 18:46:24 +09:00
Donny
797f4fff14 chore: Publish crates 2021-11-09 16:13:52 +09:00
OJ Kwon
8fe0d2583f
fix(es/transforms/compat): Apply regenerator for default function declarations (#2681)
swc_ecma_transforms_compat:
 - `regenerator`: Handle `DefaultDecl::Fn`. (Closes #2677)
2021-11-09 07:07:48 +00:00
Donny/강동윤
9824fdaae2
test(css/codegen): Add tests for parenthesis (#2691)
swc_css_codegen:
 - Ensure that parenthesis is preserved for support query. (https://github.com/vercel/next.js/issues/30570)
 - Ensure that parenthesis is preserved for media query. (https://github.com/vercel/next.js/issues/30480)
2021-11-09 15:48:38 +09:00
Donny/강동윤
22ce68cfaa
fix(swc): Don't print same error twice (#2692) 2021-11-09 15:18:11 +09:00
Donny
bcf1cfa6a1 chore: Publish crates 2021-11-09 15:17:27 +09:00
RiESAEX
7ab3b5b0b8
fix(es/transforms/react): Fix handling of whitespaces (#2638)
swc_ecma_transforms_react:
 - `jsx`: Preserve more whitespaces in input. (Closes #2208)
2021-11-09 06:10:23 +00:00
Alexander Akait
ca2338edbd
test(css/parser): Add a test for BOM (#2686) 2021-11-09 05:46:26 +00:00
Donny/강동윤
368b9e2ff2
chore: Update rustc to prevent CVE-2021-42574 (#2690) 2021-11-09 14:20:02 +09:00
Donny
7e259abae1 chore: Publish crates 2021-11-08 16:26:51 +09:00
Alexander Akait
465c18860e
fix(css/parse): Fix parsing of pseudo elements and pseudo classes (#2672)
swc_css_parser:
 - Exclude whitespaces from pseudo elements and pseudo classes.
2021-11-08 07:22:11 +00:00
Donny
76d9ae7656 chore: Publish crates 2021-11-08 16:01:09 +09:00
OJ Kwon
891591382d
refactor(es/transforms/bugfix): Migrate edge_default_param to VisitMut (#2676) 2021-11-08 06:28:51 +00:00
Donny
6b478ccce0 chore: Publish crates 2021-11-08 15:05:21 +09:00
Alexander Akait
4484d64f94
refactor(css/ast): Remove UniversalSelector (#2673) 2021-11-08 04:29:52 +00:00
Donny
98fc40988c chore: Publish crates 2021-11-08 13:06:54 +09:00
OJ Kwon
01727c0e5a
fix(es/transforms/async_to_generator): Fix handling of this (#2667)
swc_emca_transforms_compat:
 - `async_to_generator`: Do not bind `this` to generator for prototypes.
2021-11-08 12:39:14 +09:00
Donny
fd14b4f1dd chore: Publish crates 2021-11-08 00:29:47 +09:00
Alexander Akait
75e6e08e14
refactor(css/ast): Refactor complex selector to represent all css (#2660)
swc_css_ast:
 - Add a type to represent a child of `ComplexSelector`.
2021-11-08 00:29:25 +09:00
OJ Kwon
94cb4303ae
refactor: Remove trailing whitespace (#2668) 2021-11-07 20:46:12 +09:00
Donny
999ad77a3d chore: Publish crates 2021-11-07 02:27:34 +09:00
Alexander Akait
6ae3af3673
feat(css/ast): Add nested selector (#2641) 2021-11-06 16:58:41 +00:00
Donny
5c2479c005 chore: Publish crates 2021-11-07 01:19:57 +09:00
Alexander Akait
c361982963
refactor(css/ast): Rename NamespacedName to TypeSelector (#2642) 2021-11-06 16:01:50 +00:00
Donny
b3fd7046d7 chore: Publish crates 2021-11-06 18:35:38 +09:00
Alexander Akait
a8e4c72f33
fix(css/parser): Exclude whitespace from span (#2659) 2021-11-06 09:32:24 +00:00
Donny/강동윤
3dc1e765e9
feat(swc): Provide &Program to pass creator (#2665)
swc:
 - Use `impl |prorgram: &Program| -> impl Fold` instead of `impl Fold`. (Closes https://github.com/swc-project/swc/issues/2664)
2021-11-06 18:05:10 +09:00
Donny
0240beccdf chore: Publish crates 2021-11-05 20:48:06 +09:00
Alexander Akait
20f4e2148c
refactor(css/ast): Use names from specification for ast types (#2643)
swc_css_ast:
 - Rename `AttrSelectorOp` to `AttrSelectorMatcher`.
2021-11-05 11:42:51 +00:00
Donny/강동윤
994c9655c8
feat(es/ast): Add utils (#2657)
swc_ecma_ast:
 - Add `as_ident` to `PatOrExpr`.
 - Add `as_ident_mut` to `PatOrExpr`.
 - Replace `Is` macro for `ParOrExpr` with custom impl.
2021-11-05 16:09:08 +09:00
Donny
224972f487 chore: Publish crates 2021-11-05 05:14:56 +09:00
Sosuke Suzuki
d1523dc5e8
fix(es/transforms/compat): Fix static blocks (#2652)
swc_ecma_transforms_compat:
 - `static_blocks`: Use correct name for generated private properties.
2021-11-05 05:14:24 +09:00
Donny/강동윤
a6836368a2
fix(plugin): Fix serialization and deserialization (#2651)
swc_plugin_api:
 - Add `serialize_ast`.
 - Add `deserialize_ast`.
2021-11-04 21:15:18 +09:00
magic-akari
b6a5656f69
fix(node/types): Add es6 to ModuleConfig (#2648) 2021-11-04 11:43:48 +00:00
Donny
46e32a6a72 chore: Publish crates 2021-11-04 19:59:54 +09:00
Donny/강동윤
0414c31480
feat(es/ast): Implement Take for more types (#2649) 2021-11-04 19:59:28 +09:00