Comments (3)
👍
from uglifyjs.
This use case is pretty fundamental for AMD usage. In many scenarios, this is the recommended way of writing modules with RequireJS.
RequireJS then uses Function.toString
to parse out the require statements.
define(function(require) {
var p = require('some-module');
return ...;
});
Uglified, this becomes:
define(function(n) {
var p = n('some-module');
return ...;
});
If not a general except
handling, at least this use case needs to be catered for. It will start becoming more common as dynamic modules are loaded minified but without running builds with the r.js optimizer. For example jQuery core has this.
from uglifyjs.
except
will continue to exist.- I think
--reserved
is more clear as a CLI argument, but if you have a strong need for--except
we could add an alias. - You can pass an object to
.minify()
. Themangle
key will be given tomangle_names
I'm closing this for now. If your issue hasn't been resolved properly, please let us know!
from uglifyjs.
Related Issues (20)
- Lacks support for Lambda Expressions (Mozilla AST Specifications) HOT 5
- Breaking change. HOT 5
- Argument names should not be reused as variables when `arguments` is referenced in a function HOT 1
- [email protected] eliminates "use strict" where it's needed HOT 2
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure HOT 1
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure
- ufuzz failure
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from uglifyjs.