Ecosyste.ms: OpenCollective

An open API service for software projects hosted on Open Collective.

github.com/terser/terser

🗜 JavaScript parser, mangler and compressor toolkit for ES6+
https://github.com/terser/terser

employ a better parser for command-line arguments

to support passing commas in strings in for example:

uglifyjs2 -cd TEST="'a,b'" <<EOF
c...

a21f3c6cdd27696770b5cc605b5f02d81f0a32af authored about 12 years ago by Mihai Bazon <[email protected]>
the `sort` option is broken anyway, removed it

we need to mangle names from outermost to innermost scope; mangling names
from inner scopes befo...

8f664585983e4174bb850e3975659127eb99df36 authored about 12 years ago by Mihai Bazon <[email protected]>
add `semicolons` option in the code generator (default: `true`)

pass `false` to separate statements with newlines instead of semicolons

6472f9410ec93c4f934643d7fd7ff3edeef6b191 authored about 12 years ago by Mihai Bazon <[email protected]>
fix small glitches in source map generation

8957b3a694195a6e049472f7ef463b4ae3c0f8b8 authored about 12 years ago by Mihai Bazon <[email protected]>
disable warnings in the test suite

1ffd5265545c80babc9e7002ff42a64a0453d589 authored about 12 years ago by Mihai Bazon <[email protected]>
drop unused function arguments

also add test for "drop_unused" (the last one fails for now)

fcc0229087c4efd212a1050f38d3049d52344b3a authored about 12 years ago by Mihai Bazon <[email protected]>
add parens to AST_Seq whose parent is AST_Unary

b071c9d079e3acbfb521a6634364c5816d3be280 authored about 12 years ago by Mihai Bazon <[email protected]>
fix compressing benchmark.js (it tried to evaluate a statement)

the following code in benchmark.js triggered the issue:

support.decompilation = Function(
...

851b48e4a3ecdbe7d77ec827f94d67092d2890ef authored about 12 years ago by Mihai Bazon <[email protected]>
minor

708abb1ab141c737a70fca9e0af839a0b68d9db0 authored about 12 years ago by Mihai Bazon <[email protected]>
fix regression from fb5c01c073d06034815d5f3b782fd11cbdf6d6f5

is_digit takes a char code now, not a string

370d3e09172c35e4f0a7c6a47edd53625b6e2012 authored about 12 years ago by Mihai Bazon <[email protected]>
fix end tokens in spidermonkey ast import

b51fe0dcc348fe2c3942b04c7c7d88f3fb7eaa49 authored about 12 years ago by Mihai Bazon <[email protected]>
update for acorn

70d205c447c05d053c953659d3ddc41759e37579 authored about 12 years ago by Mihai Bazon <[email protected]>
minor

8149be551e238442e9378f8ef4e5eaa2554bf9bf authored about 12 years ago by Mihai Bazon <[email protected]>
actually enable the option that drops unused names in the test of issue #12

ba3df646c0ce2a8997937423c9df9d2da0670ded authored about 12 years ago by Mihai Bazon <[email protected]>
remove the $self hack

operations are destructive anyway, so there's no point to clone the nodes in
the transformer. s...

1b6f8d463f15c5a3fa27b55be0a6d2dc74bcc12a authored about 12 years ago by Mihai Bazon <[email protected]>
add test for issue #12

731fa9c2360334d374593ea0a79031d24c9c7107 authored about 12 years ago by Mihai Bazon <[email protected]>
fix in_boolean_context() (two tests were broken)

72cb5328ee58307ccb9bc91ac5826c3a41aac4d2 authored about 12 years ago by Mihai Bazon <[email protected]>
use AST_Lambda for object setters/getters

so that the optimization that drops the name if unused doesn't apply.
close #12

fc39553714ab747339c11173e11ca95aaea1ed0c authored about 12 years ago by Mihai Bazon <[email protected]>
fix pos in syntax error exception

d9d67317b1283886b24fec9a4c6607bf729a5e59 authored about 12 years ago by Mihai Bazon <[email protected]>
stealing more hacks from acorn in the name of speed

fb5c01c073d06034815d5f3b782fd11cbdf6d6f5 authored about 12 years ago by Mihai Bazon <[email protected]>
using makeComparator from acorn to generate functions that tests whether a

string is keyword, reserved etc.

speeds up the parser a bit, though not spectacular.. still far ...

f4584af42c8baa0a8f221adf1ff9a85765163e4b authored about 12 years ago by Mihai Bazon <[email protected]>
cleanup

- use prototype-less objects where feasible (minor speed improvement)
- get rid of HOP

172aa7a93ccd39feceefa058ad008e19eec0a073 authored about 12 years ago by Mihai Bazon <[email protected]>
fix propagation of symbol references

5053a29bc0b723bbf468f50e0434c3eff38600e2 authored about 12 years ago by Mihai Bazon <[email protected]>
disable warnings by default in `minify` (pass warnings: true to enable)

close #11

f322b32e0e8df5b60f577da401922f11048f2f87 authored about 12 years ago by Mihai Bazon <[email protected]>
fix node name

9cdaed9860e22513b76f8fe0ad74c1fa2faaf4d9 authored about 12 years ago by Mihai Bazon <[email protected]>
seems cleaner if AST_Label doesn't inherit from AST_SymbolDeclaration

dacce1b1fad07f5e62d62c52f05a42aa19c0e434 authored about 12 years ago by Mihai Bazon <[email protected]>
small improvements in wrap_commonjs:

- use MAP.splice instead of a BlockStatement to inject code (avoids some
warnings in the linte...

f26f3b44bc238c5ea9772ccea5a21c9c928b6fd9 authored about 12 years ago by Mihai Bazon <[email protected]>
drop unused variable

c5ecbfc756a4ed0aa736a82a062441b97effa7f5 authored about 12 years ago by Mihai Bazon <[email protected]>
add `--lint` and display {file} in scope_warnings

3799ac8973bb0bd08efe7a2af27808e5917183cc authored about 12 years ago by Mihai Bazon <[email protected]>
minor

86182afa7f3c6d6159e2ade7b88306ab1f62832b authored about 12 years ago by Mihai Bazon <[email protected]>
update on @cc_on

4807c6e75686ea722a2424e7a1dd369225c1be3b authored about 12 years ago by Mihai Bazon <[email protected]>
add AST_Infinity node

a84d07e31298fc1f8825b0047629634920667707 authored about 12 years ago by Mihai Bazon <[email protected]>
make `--comments` keep @cc_on too

88beddfa91c8f362cc74538937ce883541e77680 authored about 12 years ago by Mihai Bazon <[email protected]>
added $propdoc to AST nodes and some cleanups

hopefully we can make the AST documentation self-generating

1b0aab2ce9e7f429ceeda98ee0cda448085918ec authored about 12 years ago by Mihai Bazon <[email protected]>
minor AST cleanup (AST_BlockStatement may inherit from AST_Block)

9ead49641da82de3a27ed813a056628f83da379c authored about 12 years ago by Mihai Bazon <[email protected]>
add `--ast-help`

displays a rather cruel description of the AST classes, derived
directly from the node definitions.

e1862cd36f147e410c003c9daee5fd2befdf9a42 authored about 12 years ago by Mihai Bazon <[email protected]>
fix detecting symbols in use

2c025f23db6efb6d1442208d81c2080d40c44f10 authored about 12 years ago by Mihai Bazon <[email protected]>
Merge pull request #8 from SevInf/master

Fix crash in minify function

9dfcd47ec8fef20a7c6f994bb8896a16ffa0eb2b authored about 12 years ago by Mihai Bazon <[email protected]>
Fix nodejs minify without inSourceMap exception

When inSourceMap is omitted fs.readFile throws exception. Fixed version
calls fs.readFile only w...

203ecaf85ba7ad714e77c78b2102309d5581948c authored about 12 years ago by Sergej Tatarincev <[email protected]>
fix `inSourceMap` in `minify` (should read the file)

c967f0b0fefd7db03922769f1d2aaf2ae1394ddc authored about 12 years ago by Mihai Bazon <[email protected]>
add simple API wrapper: UglifyJS.minify

(refs #7)

dfc04e66770f463e1ae97547950e6b829aaeeeff authored about 12 years ago by Mihai Bazon <[email protected]>
added some basic API doc

42ea3c95e0ef4d7831b466c6a42e06705fd31535 authored about 12 years ago by Mihai Bazon <[email protected]>
should not expose base54.sort() in the API docs, I think

d4970b35acb6142157e3f6dd4505ae0e44a175c6 authored about 12 years ago by Mihai Bazon <[email protected]>
added --self to easily get a browser-runnable version of UglifyJS

dd8286bce152125d18a0af13a6088049303f2993 authored about 12 years ago by Mihai Bazon <[email protected]>
eliminate redundant directives in the same scope

093a9031dc15b2e2bd85850f3f3eb7fe90f01bd7 authored about 12 years ago by Mihai Bazon <[email protected]>
for certain nodes that we invent we might not have a original source file to

map from, so just use "?". and in any case, don't fail hard when addMapping throws.

80a18fe2fa60d8a689516b921a386839d30b6abe authored about 12 years ago by Mihai Bazon <[email protected]>
fix typo

fe1411bba1368c4e3c1fe92459e956ec4a4c5ee6 authored about 12 years ago by Mihai Bazon <[email protected]>
remove unused code

455ac5435d2adca919ec6fd4e195af75aa0f09fe authored about 12 years ago by Mihai Bazon <[email protected]>
minor

4a2b91220a9bda0f8257dde72c7b35e50fecf341 authored about 12 years ago by Mihai Bazon <[email protected]>
replace `(function(){ ...no side effects ... })()` with `undefined`.

a1e088593068a59ea7e620dc0cf412f1c01caa86 authored about 12 years ago by Mihai Bazon <[email protected]>
prevent mangling only when eval is *called*, not when it's just referenced

7ae09120ed5080ef09760def08dd7803ec977b1b authored about 12 years ago by Mihai Bazon <[email protected]>
add note about installation

42c25d901cb62917723b0b09285921de73d6eb6d authored about 12 years ago by Mihai Bazon <[email protected]>
added --acorn and --spidermonkey options

e88dcc3819bd5af933d124fc5bf2b021366d5f28 authored about 12 years ago by Mihai Bazon <[email protected]>
fixed import of locations from SpiderMonkey AST

ecd9f21467c32b6a0076a99bdd895cf37244683a authored about 12 years ago by Mihai Bazon <[email protected]>
use the appropriate constructor for symbols

a9b6f9909a331740cae4a37f1fc6bb40801674fe authored about 12 years ago by Mihai Bazon <[email protected]>
minor

708ec0467cc584a1cbc377f9d724084357ca5d1a authored about 12 years ago by Mihai Bazon <[email protected]>
removed some unused variables

682a58a1f55d171a1705bdb16ec98e5c2ec855a1 authored about 12 years ago by Mihai Bazon <[email protected]>
moving code around

f20c25188297d8a18e81c01af10986b23d90671c authored about 12 years ago by Mihai Bazon <[email protected]>
define AST_Node.from_mozilla_ast(ast)

returns an UglifyJS2 AST given a Mozilla AST. Still needs some work to do
(need to create speci...

2bd8a118c273853848e4231c98f833757dda18b0 authored about 12 years ago by Mihai Bazon <[email protected]>
ignore tmp/

42ce7ed6067b45afa244ec96f1c1a766a8f98ffe authored about 12 years ago by Mihai Bazon <[email protected]>
more cleanup (dropped AST_SwitchBlock)

11863d6f9a48d6c7194ad65f9cc140292aedc948 authored about 12 years ago by Mihai Bazon <[email protected]>
AST cleanup (dropped AST_StatementBase)

3412498795cfeb4c5700c39e05f895c96412695f authored about 12 years ago by Mihai Bazon <[email protected]>
added package.json

9221ad62dbca2d9cccd252ddc1344f221767bc96 authored about 12 years ago by Mihai Bazon <[email protected]>
added option for side-effect-free statements, fix test

c11de17e99fed5181f4be6e7a803aa92edce5459 authored about 12 years ago by Mihai Bazon <[email protected]>
fix endless loop in tests

e0f5075e45b8914d2543238565f771d4822117ca authored about 12 years ago by Mihai Bazon <[email protected]>
drop tmp. files

bd94eeb6f7ba5a6cbc8f9547766857d9873f862a authored about 12 years ago by Mihai Bazon <[email protected]>
document the CLI tool

7e8880be1cb24d628eed183c87479ff01f7b7848 authored about 12 years ago by Mihai Bazon <[email protected]>
fix for `a = !b && !c && !d && !e → a=!(b||c||d||e)`

0678ae2076a9f817ecb8837279c24cf54ea819c2 authored about 12 years ago by Mihai Bazon <[email protected]>
disable `hoist_vars` by default and change `comparations` to `comparisons`

378ed178095e8d02b8ceab9d6d8e890eea1ab04d authored about 12 years ago by Mihai Bazon <[email protected]>
fixed usage string

5c151f90b3bc14080072d41fd589dc74ff859fc6 authored about 12 years ago by Mihai Bazon <[email protected]>
support for `--comments` option to keep comments containing @license or @preserve

815abcfe1847c10fb257f5651561272743c1f754 authored about 12 years ago by Mihai Bazon <[email protected]>
discard annoying nodejs warning

cb2e811191238eb5adfa3560630770649fe29ec9 authored about 12 years ago by Mihai Bazon <[email protected]>
line numbers start at 1

075f93ec0dd8a86a87632ac1e2b1aac3b115f7c0 authored about 12 years ago by Mihai Bazon <[email protected]>
added option to keep some comments in the output

2a5456260e01af2228356edfb6e31e3946fcbd91 authored about 12 years ago by Mihai Bazon <[email protected]>
option to exclude certain names from mangling

36be211e99ec7c65e156499d53f471a1e55a6fd1 authored about 12 years ago by Mihai Bazon <[email protected]>
support defines

dde5b22b5e99d4a75c8918659b7f73abed436ce2 authored about 12 years ago by Mihai Bazon <[email protected]>
"use strict";

e1098b04a7e8b3ebd4faf598b2b8b30bceba14d6 authored about 12 years ago by Mihai Bazon <[email protected]>
more constant folding (for names defined with `const`)

211792757cf8cb8529f99122efa52f5f5d558132 authored about 12 years ago by Mihai Bazon <[email protected]>
add AST_SymbolConst for names defined with `const`

347160c63138dcd7fbe107ae80309ad86d58a2e1 authored about 12 years ago by Mihai Bazon <[email protected]>
drop more unused names

ff696cd7bc507ad0ffc5444bff39de9b6ad10a7e authored about 12 years ago by Mihai Bazon <[email protected]>
a shy attempt to obey `width` in the beautifier; added `bracketize` option to always print brackets around if/do/while/for statements; export more options via the CLI

9e5dd81f1e98b5c77084e19345191d630576cc44 authored about 12 years ago by Mihai Bazon <[email protected]>
minor

896444482a4044c21b68a1eb58cfe8639b628279 authored about 12 years ago by Mihai Bazon <[email protected]>
fix mangling

(bug in our code prevented the mangler from using a name that was in use
prior to mangling but n...

05e15b1c0c04f673524e0946b5e1b6a60110ada1 authored about 12 years ago by Mihai Bazon <[email protected]>
removed the "squeeze" method (it's now effectively "transform")

13278c6649189ffea363ac51be5f6b9738e04ff7 authored about 12 years ago by Mihai Bazon <[email protected]>
some speedup and more savings from unused vars that have side effects in initialization

15d58f5917cba980754553a1578c9d339cc7b419 authored about 12 years ago by Mihai Bazon <[email protected]>
compressor successfully moved to TreeTransformer

78be8f52964ab9d391fedc0dc2cc9315fcb56437 authored about 12 years ago by Mihai Bazon <[email protected]>
checkpoint (refactoring, WIP)

a24e7ee976787915c4d8f232bc980174674edb0b authored about 12 years ago by Mihai Bazon <[email protected]>
minor

e979d01f048a7d1e0fe80e782af107a54ec0c5d0 authored about 12 years ago by Mihai Bazon <[email protected]>
more cleanups

242dd101313e1698b731954f551bef9014cc9b0f authored about 12 years ago by Mihai Bazon <[email protected]>
moving code around (refactoring, WIP)

9321d418bc76b299bfcc627f6dafb49df1832881 authored about 12 years ago by Mihai Bazon <[email protected]>
discard all \uFEFF characters (https://github.com/mishoo/UglifyJS/issues/462)

10c7f52074718b506d9ebfe5cc5a9c7dd9c25b5a authored about 12 years ago by Mihai Bazon <[email protected]>
started some refactoring (WIP) -- moving squeezer to TreeTransformer

4201577dd7c75c1d1b1bddf5c153373275b8e977 authored about 12 years ago by Mihai Bazon <[email protected]>
minor

e836e2ae5fbc61731a9b59b075310f0234c948bc authored about 12 years ago by Mihai Bazon <[email protected]>
it's not safe to assume that property access is side-effect-free

(getters/setters + various browser bugs will trigger side effects; also, an
exception is thrown ...

ea6d1ea7014352ed81bf8d1fd461727d21ff4d12 authored about 12 years ago by Mihai Bazon <[email protected]>
some boolean cleanup

368ac8f93ca7ea704ee0eabd419cd083c6b843aa authored about 12 years ago by Mihai Bazon <[email protected]>
Support input source map

This is useful while compressing generated code; for example compressing JS
compiled by CoffeeSc...

42038fd67f49be16a01be8a7f8085d9a52f13c50 authored about 12 years ago by Mihai Bazon <[email protected]>
minor tests fix

4f97da96608744e9f20c3994d8d1e66d6b6949a1 authored about 12 years ago by Mihai Bazon <[email protected]>
properly drop mutually-referring declarations that are not otherwise

referenced and have no side effects

a83b28503f4673aeb744b45306500584a6480e29 authored about 12 years ago by Mihai Bazon <[email protected]>
tree transformer api (WIP)

76d88b59dcd28b836b2cdaf7908bfd5acaa88ebc authored over 12 years ago by Mihai Bazon <[email protected]>
log filename in parse errors / compressor warnings

ec7f895b54924e90e17d828cfd7db4c62830f93d authored over 12 years ago by Mihai Bazon <[email protected]>