mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
# add dist
This commit is contained in:
19
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/LICENSE
generated
vendored
Normal file
19
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,19 @@
|
||||
Copyright (c) 2013 Forbes Lindesay
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
15
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/README.md
generated
vendored
Normal file
15
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/README.md
generated
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
# uglify-to-browserify
|
||||
|
||||
A transform to make UglifyJS work in browserify.
|
||||
|
||||
[](https://travis-ci.org/ForbesLindesay/uglify-to-browserify)
|
||||
[](https://gemnasium.com/ForbesLindesay/uglify-to-browserify)
|
||||
[](http://badge.fury.io/js/uglify-to-browserify)
|
||||
|
||||
## Installation
|
||||
|
||||
npm install uglify-to-browserify
|
||||
|
||||
## License
|
||||
|
||||
MIT
|
49
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/index.js
generated
vendored
Normal file
49
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/index.js
generated
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
'use strict'
|
||||
|
||||
var fs = require('fs')
|
||||
var PassThrough = require('stream').PassThrough
|
||||
var Transform = require('stream').Transform
|
||||
|
||||
if (typeof Transform === 'undefined') {
|
||||
throw new Error('UglifyJS only supports browserify when using node >= 0.10.x')
|
||||
}
|
||||
|
||||
var cache = {}
|
||||
module.exports = transform
|
||||
function transform(file) {
|
||||
if (!/tools\/node\.js$/.test(file.replace(/\\/g,'/'))) return new PassThrough();
|
||||
if (cache[file]) return makeStream(cache[file])
|
||||
var uglify = require(file)
|
||||
var src = 'var sys = require("util");\nvar MOZ_SourceMap = require("source-map");\nvar UglifyJS = exports;\n' + uglify.FILES.map(function (path) { return fs.readFileSync(path, 'utf8') }).join('\n')
|
||||
|
||||
var ast = uglify.parse(src)
|
||||
ast.figure_out_scope()
|
||||
|
||||
var variables = ast.variables
|
||||
.map(function (node, name) {
|
||||
return name
|
||||
})
|
||||
|
||||
src += '\n\n' + variables.map(function (v) { return 'exports.' + v + ' = ' + v + ';' }).join('\n') + '\n\n'
|
||||
|
||||
src += 'exports.AST_Node.warn_function = function (txt) { if (typeof console != "undefined" && typeof console.warn === "function") console.warn(txt) }\n\n'
|
||||
|
||||
src += 'exports.minify = ' + uglify.minify.toString() + ';\n\n'
|
||||
src += 'exports.describe_ast = ' + uglify.describe_ast.toString() + ';'
|
||||
|
||||
// TODO: remove once https://github.com/substack/node-browserify/issues/631 is resolved
|
||||
src = src.replace(/"for"/g, '"fo" + "r"')
|
||||
|
||||
cache[file] = src
|
||||
return makeStream(src);
|
||||
}
|
||||
|
||||
function makeStream(src) {
|
||||
var res = new Transform();
|
||||
res._transform = function (chunk, encoding, callback) { callback() }
|
||||
res._flush = function (callback) {
|
||||
res.push(src)
|
||||
callback()
|
||||
}
|
||||
return res;
|
||||
}
|
72
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/package.json
generated
vendored
Normal file
72
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/package.json
generated
vendored
Normal file
@@ -0,0 +1,72 @@
|
||||
{
|
||||
"_args": [
|
||||
[
|
||||
"uglify-to-browserify@~1.0.0",
|
||||
"/Users/mromano/dev/dev-platform-webcomponents/ng2-components/ng2-alfresco-documentslist/node_modules/systemjs-builder/node_modules/uglify-js"
|
||||
]
|
||||
],
|
||||
"_from": "uglify-to-browserify@>=1.0.0 <1.1.0",
|
||||
"_id": "uglify-to-browserify@1.0.2",
|
||||
"_inCache": true,
|
||||
"_installable": true,
|
||||
"_location": "/uglify-to-browserify",
|
||||
"_npmUser": {
|
||||
"email": "forbes@lindeay.co.uk",
|
||||
"name": "forbeslindesay"
|
||||
},
|
||||
"_npmVersion": "1.3.14",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"name": "uglify-to-browserify",
|
||||
"raw": "uglify-to-browserify@~1.0.0",
|
||||
"rawSpec": "~1.0.0",
|
||||
"scope": null,
|
||||
"spec": ">=1.0.0 <1.1.0",
|
||||
"type": "range"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/systemjs-builder/uglify-js"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz",
|
||||
"_shasum": "6e0924d6bda6b5afe349e39a6d632850a0f882b7",
|
||||
"_shrinkwrap": null,
|
||||
"_spec": "uglify-to-browserify@~1.0.0",
|
||||
"_where": "/Users/mromano/dev/dev-platform-webcomponents/ng2-components/ng2-alfresco-documentslist/node_modules/systemjs-builder/node_modules/uglify-js",
|
||||
"author": {
|
||||
"name": "ForbesLindesay"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/ForbesLindesay/uglify-to-browserify/issues"
|
||||
},
|
||||
"dependencies": {},
|
||||
"description": "A transform to make UglifyJS work in browserify.",
|
||||
"devDependencies": {
|
||||
"source-map": "~0.1.27",
|
||||
"uglify-js": "~2.4.0"
|
||||
},
|
||||
"directories": {},
|
||||
"dist": {
|
||||
"shasum": "6e0924d6bda6b5afe349e39a6d632850a0f882b7",
|
||||
"tarball": "https://registry.npmjs.org/uglify-to-browserify/-/uglify-to-browserify-1.0.2.tgz"
|
||||
},
|
||||
"homepage": "https://github.com/ForbesLindesay/uglify-to-browserify",
|
||||
"keywords": [],
|
||||
"license": "MIT",
|
||||
"maintainers": [
|
||||
{
|
||||
"email": "forbes@lindesay.co.uk",
|
||||
"name": "forbeslindesay"
|
||||
}
|
||||
],
|
||||
"name": "uglify-to-browserify",
|
||||
"optionalDependencies": {},
|
||||
"readme": "ERROR: No README data found!",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/ForbesLindesay/uglify-to-browserify.git"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "node test/index.js"
|
||||
},
|
||||
"version": "1.0.2"
|
||||
}
|
22
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/test/index.js
generated
vendored
Normal file
22
ng2-components/ng2-alfresco-documentslist/dist/node_modules/uglify-to-browserify/test/index.js
generated
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
var fs = require('fs')
|
||||
var br = require('../')
|
||||
var test = fs.readFileSync(require.resolve('uglify-js/test/run-tests.js'), 'utf8')
|
||||
.replace(/^#.*\n/, '')
|
||||
|
||||
var transform = br(require.resolve('uglify-js'))
|
||||
transform.pipe(fs.createWriteStream(__dirname + '/output.js'))
|
||||
.on('close', function () {
|
||||
Function('module,require', test)({
|
||||
filename: require.resolve('uglify-js/test/run-tests.js')
|
||||
},
|
||||
function (name) {
|
||||
if (name === '../tools/node') {
|
||||
return require('./output.js')
|
||||
} else if (/^[a-z]+$/.test(name)) {
|
||||
return require(name)
|
||||
} else {
|
||||
throw new Error('I didn\'t expect you to require ' + name)
|
||||
}
|
||||
})
|
||||
})
|
||||
transform.end(fs.readFileSync(require.resolve('uglify-js'), 'utf8'))
|
Reference in New Issue
Block a user