Commit 3d0d31a
committed
feat(minifier): rewrite
Reverse-transpile rest argument code generated by TypeScript and babel.
Example input:
```js
for (var e = arguments.length, r = Array(e), a = 0; a < e; a++)
r[a] = arguments[a];
```
output:
```js
var r = [...arguments];
```
It's a quite specific transform though.arguments copy loops to spread syntax (#13114)1 parent c661bac commit 3d0d31a
File tree
3 files changed
+383
-5
lines changed- crates/oxc_minifier/src/peephole
- tasks/minsize
3 files changed
+383
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
169 | 169 | | |
170 | 170 | | |
171 | 171 | | |
| 172 | + | |
172 | 173 | | |
173 | 174 | | |
174 | 175 | | |
| |||
0 commit comments