@angular-devkit/build-optimizer
Advanced tools
Comparing version 0.0.14 to 0.0.15
{ | ||
"name": "@angular-devkit/build-optimizer", | ||
"version": "0.0.14", | ||
"version": "0.0.15", | ||
"description": "Angular Build Optimizer", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -56,5 +56,7 @@ # Angular Build Optimizer | ||
Adds `/*@__PURE__*/` comments to top level downleveled class declarations and instantiation. | ||
Adds `/*@__PURE__*/` comments to top level downleveled class declarations and instantiation. | ||
Webpack library imports are also marked as `/*@__PURE__*/` when used with [Purify Plugin](#purify-plugin). | ||
Warning: this transform assumes the file is a pure module. It should not be used with unpure modules. | ||
```typescript | ||
@@ -73,2 +75,27 @@ // input | ||
### Prefix Classes | ||
Adds `/*@__PURE__*/` to downleveled TypeScript classes. | ||
```typescript | ||
// input | ||
var ReplayEvent = (function () { | ||
function ReplayEvent(time, value) { | ||
this.time = time; | ||
this.value = value; | ||
} | ||
return ReplayEvent; | ||
}()); | ||
// output | ||
var ReplayEvent = /*@__PURE__*/ (function () { | ||
function ReplayEvent(time, value) { | ||
this.time = time; | ||
this.value = value; | ||
} | ||
return ReplayEvent; | ||
}()); | ||
``` | ||
### Import tslib | ||
@@ -90,7 +117,28 @@ | ||
### Wrap enums | ||
Wrap downleveled TypeScript enums in a function, and adds `/*@__PURE__*/` comment. | ||
```typescript | ||
// input | ||
var ChangeDetectionStrategy; | ||
(function (ChangeDetectionStrategy) { | ||
ChangeDetectionStrategy[ChangeDetectionStrategy["OnPush"] = 0] = "OnPush"; | ||
ChangeDetectionStrategy[ChangeDetectionStrategy["Default"] = 1] = "Default"; | ||
})(ChangeDetectionStrategy || (ChangeDetectionStrategy = {})); | ||
// output | ||
var ChangeDetectionStrategy = /*@__PURE__*/ (function () { | ||
var ChangeDetectionStrategy = {}; | ||
ChangeDetectionStrategy[ChangeDetectionStrategy["OnPush"] = 0] = "OnPush"; | ||
ChangeDetectionStrategy[ChangeDetectionStrategy["Default"] = 1] = "Default"; | ||
return ChangeDetectionStrategy; | ||
})(); | ||
``` | ||
### Purify Plugin | ||
Performs regex based replacements on all files that add `/*@__PURE__*/` comments to downleveled classes, TypeScript | ||
enums and webpack imports (used with [Prefix functions](#prefix-functions)) | ||
Performs regex based replacements on all bundles that add `/*@__PURE__*/` comments to | ||
known pure webpack imports (used with [Prefix functions](#prefix-functions)). | ||
@@ -97,0 +145,0 @@ |
@@ -14,7 +14,6 @@ "use strict"; | ||
const import_tslib_1 = require("../transforms/import-tslib"); | ||
const prefix_classes_1 = require("../transforms/prefix-classes"); | ||
const prefix_functions_1 = require("../transforms/prefix-functions"); | ||
const scrub_file_1 = require("../transforms/scrub-file"); | ||
const hasDecorators = /decorators/; | ||
const hasCtorParameters = /ctorParameters/; | ||
const hasTsHelpers = /var (__extends|__decorate|__metadata|__param) = /; | ||
const wrap_enums_1 = require("../transforms/wrap-enums"); | ||
const isAngularModuleFile = /\.es5\.js$/; | ||
@@ -48,5 +47,11 @@ const whitelistedAngularModules = [ | ||
const getTransforms = []; | ||
if (hasTsHelpers.test(content)) { | ||
if (wrap_enums_1.testWrapEnums(content)) { | ||
getTransforms.push(wrap_enums_1.getWrapEnumsTransformer); | ||
} | ||
if (import_tslib_1.testImportTslib(content)) { | ||
getTransforms.push(import_tslib_1.getImportTslibTransformer); | ||
} | ||
if (prefix_classes_1.testPrefixClasses(content)) { | ||
getTransforms.push(prefix_classes_1.getPrefixClassesTransformer); | ||
} | ||
if (inputFilePath | ||
@@ -62,3 +67,3 @@ && isAngularModuleFile.test(inputFilePath) | ||
} | ||
else if (hasDecorators.test(content) || hasCtorParameters.test(content)) { | ||
else if (scrub_file_1.testScrubFile(content)) { | ||
getTransforms.push(scrub_file_1.getScrubFileTransformer, class_fold_1.getFoldFileTransformer); | ||
@@ -69,2 +74,2 @@ } | ||
exports.buildOptimizer = buildOptimizer; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYnVpbGQtb3B0aW1pemVyLmpzIi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JlKClgIGNhbGxzIGFuZCBgY29uc29sZS5sb2coc3R1ZmYpYCBhcyBwdXJlLlxuICAgICAgLy8gV2Ugb25seSBhcHBseSBpdCB0byB3aGl0ZWxpc3RlZCBtb2R1bGVzLCBzaW5jZSB3ZSBrbm93IHRoZXkgYXJlIHNhZmUuXG4gICAgICAvLyBnZXRQcmVmaXhGdW5jdGlvbnNUcmFuc2Zvcm1lciBuZWVkcyB0byBiZSBiZWZvcmUgZ2V0Rm9sZEZpbGVUcmFuc2Zvcm1lci5cbiAgICAgIGdldFByZWZpeEZ1bmN0aW9uc1RyYW5zZm9ybWVyLFxuICAgICAgZ2V0U2NydWJGaWxlVHJhbnNmb3JtZXIsXG4gICAgICBnZXRGb2xkRmlsZVRyYW5zZm9ybWVyLFxuICAgICk7XG4gIH0gZWxzZSBpZiAodGVzdFNjcnViRmlsZShjb250ZW50KSkge1xuICAgIGdldFRyYW5zZm9ybXMucHVzaChcbiAgICAgIGdldFNjcnViRmlsZVRyYW5zZm9ybWVyLFxuICAgICAgZ2V0Rm9sZEZpbGVUcmFuc2Zvcm1lcixcbiAgICApO1xuICB9XG5cbiAgcmV0dXJuIHRyYW5zZm9ybUphdmFzY3JpcHQoeyAuLi5vcHRpb25zLCBnZXRUcmFuc2Zvcm1zLCBjb250ZW50IH0pO1xufVxuIl19 |
@@ -50,3 +50,9 @@ "use strict"; | ||
const host = { | ||
getSourceFile: (fileName) => sourcesMap.get(fileName), | ||
getSourceFile: (fileName) => { | ||
const sourceFile = sourcesMap.get(fileName); | ||
if (!sourceFile) { | ||
throw new Error(`File ${fileName} does not have a sourceFile.`); | ||
} | ||
return sourceFile; | ||
}, | ||
getDefaultLibFileName: () => defaultLibFileName, | ||
@@ -59,3 +65,9 @@ getCurrentDirectory: () => '', | ||
fileExists: (fileName) => fileMap.has(fileName), | ||
readFile: (fileName) => fileMap.has(fileName) ? fileMap.get(fileName) : '', | ||
readFile: (fileName) => { | ||
const content = fileMap.get(fileName); | ||
if (!content) { | ||
throw new Error(`File ${fileName} does not exist.`); | ||
} | ||
return content; | ||
}, | ||
writeFile: (fileName, text) => outputs.set(fileName, text), | ||
@@ -128,2 +140,2 @@ }; | ||
exports.transformJavascript = transformJavascript; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidHJhbnNmb3JtLWphdmFzY3JpcHQuanMiLCJzb3VyY2VSb290IjoiL1VzZXJzL2hhbnNsL1NvdXJjZXMvZGV2a2l0LyIsInNvdXJjZXMiOlsicGFja2FnZXMvYW5ndWxhcl9kZXZraXQvYnVpbGRfb3B0aW1pemVyL3NyYy9oZWxwZXJzL3RyYW5zZm9ybS1qYXZhc2NyaXB0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7O0FBQUE7Ozs7OztHQU1HO0FBQ0gsMkJBQWtDO0FBQ2xDLCtCQUFxQztBQUVyQyxpQ0FBaUM7QUFrQmpDLDZCQUNFLE9BQW1DO0lBR25DLE1BQU0sRUFDSixPQUFPLEVBQ1AsYUFBYSxFQUNiLGFBQWEsRUFDYixhQUFhLEVBQ2IsY0FBYyxFQUNkLE1BQU0sR0FDUCxHQUFHLE9BQU8sQ0FBQztJQUVaLHNDQUFzQztJQUN0QyxFQUFFLENBQUMsQ0FBQyxhQUFhLENBQUMsTUFBTSxLQUFLLENBQUMsQ0FBQyxDQUFDLENBQUM7UUFDL0IsTUFBTSxDQUFDO1lBQ0wsT0FBTyxFQUFFLElBQUk7WUFDYixTQUFTLEVBQUUsSUFBSTtZQUNmLFdBQVcsRUFBRSxJQUFJO1NBQ2xCLENBQUM7SUFDSixDQUFDO0lBRUQsMkJBQTJCO0lBQzNCLE1BQU0sZ0JBQWdCLEdBQUcsQ0FBQyxXQUE0QjtRQUNwRCxFQUFFLENBQUMsQ0FBQyxXQUFXLElBQUksV0FBVyxDQUFDLE1BQU0sR0FBRyxDQUFDLENBQUMsQ0FBQyxDQUFDO1lBQzFDLElBQUksTUFBTSxHQUFHLEV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QYXRoKSB7XG4gICAgICBzb3VyY2VNYXAuZmlsZSA9IG91dHB1dEZpbGVQYXRoO1xuICAgICAgdHJhbnNmb3JtZWRDb250ZW50ID0gdHJhbnNmb3JtZWRDb250ZW50LnJlcGxhY2UodXJsUmVnRXhwLFxuICAgICAgICBgLy8jIHNvdXJjZU1hcHBpbmdVUkw9JHtzb3VyY2VNYXAuZmlsZX0ubWFwXFxuYCk7XG4gICAgICBpZiAoaW5wdXRGaWxlUGF0aCkge1xuICAgICAgICBzb3VyY2VNYXAuc291cmNlcyA9IFtpbnB1dEZpbGVQYXRoXTtcbiAgICAgIH0gZWxzZSB7XG4gICAgICAgIHNvdXJjZU1hcC5zb3VyY2VzID0gWycnXTtcbiAgICAgIH1cbiAgICB9IGVsc2Uge1xuICAgICAgLy8gVE9ETzogZmlndXJlIG91dCBpZiB3ZSBzaG91bGQgaW5saW5lIHNvdXJjZXMgaGVyZS5cbiAgICAgIHRyYW5zZm9ybWVkQ29udGVudCA9IHRyYW5zZm9ybWVkQ29udGVudC5yZXBsYWNlKHVybFJlZ0V4cCwgJycpO1xuICAgICAgc291cmNlTWFwLmZpbGUgPSAnJztcbiAgICAgIHNvdXJjZU1hcC5zb3VyY2VzID0gWycnXTtcbiAgICB9XG4gIH1cblxuICByZXR1cm4ge1xuICAgIGNvbnRlbnQ6IHRyYW5zZm9ybWVkQ29udGVudCxcbiAgICBzb3VyY2VNYXAsXG4gICAgZW1pdFNraXBwZWQ6IGZhbHNlLFxuICB9O1xufVxuIl19 |
@@ -16,12 +16,2 @@ "use strict"; | ||
const newContent = content | ||
.replace( | ||
// tslint:disable-next-line:max-line-length | ||
/^(var (\S+) = )(\(function \(\) \{\r?\n(?: (?:\/\*\*| \*|\*\/|\/\/)[^\r?\n]*\r?\n)* function \2\([^\)]*\) \{\r?\n)/mg, '$1/*@__PURE__*/$3') | ||
.replace(/^(var (\S+) = )(\(function \(_super\) \{\r?\n \w*__extends\(\w+, _super\);\r?\n)/mg, '$1/*@__PURE__*/$3') | ||
.replace( | ||
// tslint:disable-next-line:max-line-length | ||
/var (\S+) = \{\};\r?\n(\1\.(\S+) = \d+;\r?\n)+\1\[\1\.(\S+)\] = "\4";\r?\n(\1\[\1\.(\S+)\] = "\S+";\r?\n*)+/mg, 'var $1 = /*@__PURE__*/(function() {\n$&; return $1;})();\n') | ||
.replace( | ||
// tslint:disable-next-line:max-line-length | ||
/var (\S+);(\/\*@__PURE__\*\/)*\r?\n\(function \(\1\) \{\s+(\1\[\1\["(\S+)"\] = 0\] = "\4";(\s+\1\[\1\["\S+"\] = \d\] = "\S+";)*\r?\n)\}\)\(\1 \|\| \(\1 = \{\}\)\);/mg, 'var $1 = /*@__PURE__*/(function() {\n var $1 = {};\n $3 return $1;\n})();') | ||
.replace(new RegExp(`(_(${pureImportMatches})__ = )(__webpack_require__\\(\\S+\\);)`, 'mg'), '$1/*@__PURE__*/$3') | ||
@@ -43,2 +33,2 @@ .replace(new RegExp(`(_(${pureImportMatches})___default = )(__webpack_require__\\.\\w\\(\\S+\\);)`, 'mg'), '$1/*@__PURE__*/$3') | ||
} | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVyaWZ5LmpzIiwic291cmNlUm9vdCI6Ii9Vc2Vycy9oYW5zbC9Tb3VyY2VzL2RldmtpdC8iLCJzb3VyY2VzIjpbInBhY2thZ2VzL2FuZ3VsYXJfZGV2a2l0L2J1aWxkX29wdGltaXplci9zcmMvcHVyaWZ5L3B1cmlmeS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBOzs7Ozs7R0FNRztBQUNILHFGQUFxRjtBQUNyRixNQUFNLGtCQUFrQixHQUFHLHlEQUF5RCxDQUFDO0FBRXJGLDBCQUEwQjtBQUMxQixnQkFBdUIsT0FBZTtJQUVwQyxNQUFNLGlCQUFpQixHQUFHLFVBQVUsQ0FBQyxPQUFPLEVBQUUsa0JBQWtCLEVBQUUsQ0FBQyxDQUFDL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W1iZXIpIHtcbiAgbGV0IG1hdGNoZXM6IHN0cmluZ1tdID0gW107XG4gIGxldCBtYXRjaDtcbiAgLy8gdHNsaW50OmRpc2FibGUtbmV4dC1saW5lOm5vLWNvbmRpdGlvbmFsLWFzc2lnbm1lbnRcbiAgd2hpbGUgKG1hdGNoID0gcmVnZXguZXhlYyhzdHIpKSB7XG4gICAgbWF0Y2hlcyA9IG1hdGNoZXMuY29uY2F0KG1hdGNoW2luZGV4XS5zcGxpdCgnLCcpKTtcbiAgfVxuXG4gIHJldHVybiBtYXRjaGVzO1xufVxuIl19 |
@@ -9,2 +9,3 @@ /** | ||
import * as ts from 'typescript'; | ||
export declare function testImportTslib(content: string): boolean; | ||
export declare function getImportTslibTransformer(): ts.TransformerFactory<ts.SourceFile>; |
@@ -11,2 +11,7 @@ "use strict"; | ||
const ts = require("typescript"); | ||
function testImportTslib(content) { | ||
const regex = /var (__extends|__decorate|__metadata|__param) = \(.*\r?\n( .*\r?\n)*\};/; | ||
return regex.test(content); | ||
} | ||
exports.testImportTslib = testImportTslib; | ||
function getImportTslibTransformer() { | ||
@@ -100,2 +105,2 @@ return (context) => { | ||
} | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW1wb3J0LXRzbGliLmpzIiwic291cmNlUm9vdCI6Ii9Vc2Vycy9oYW5zbC9Tb3VyY2VzL2RldmtpdC8iLCJzb3VyY2VzIjpbInBhY2thZ2VzL2FuZ3VsYXJfZGV2a2l0L2J1aWxkX29wdGltaXplci9zcmMvdHJhbnNmb3Jtcy9pbXBvcnQtdHNsaWIudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQTs7Ozs7O0dBTUc7QUFDSCxpQ0FBaUM7QUFHakM7SUFDRSxNQUFNLENBQUMsQ0FBQyxPQUFpQztRQUV2QyxNQUFNLFdBQVcsR0FBa0MsQ0FBQyxFQUFpQjtZQUVuRSwrRUFBK0U7WUFDL0UsTUFBTSx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RlbWVudE5hbWUobm9kZTogdHMuTm9kZSkge1xuICBjb25zdCB2YXJTdG10ID0gbm9kZSBhcyB0cy5WYXJpYWJsZVN0YXRlbWVudDtcbiAgaWYgKHZhclN0bXQuZGVjbGFyYXRpb25MaXN0LmRlY2xhcmF0aW9ucy5sZW5ndGggPiAxKSB7XG4gICAgcmV0dXJuIG51bGw7XG4gIH1cbiAgY29uc3QgdmFyRGVjbCA9IHZhclN0bXQuZGVjbGFyYXRpb25MaXN0LmRlY2xhcmF0aW9uc1swXTtcbiAgaWYgKHZhckRlY2wubmFtZS5raW5kICE9PSB0cy5TeW50YXhLaW5kLklkZW50aWZpZXIpIHtcbiAgICByZXR1cm4gbnVsbDtcbiAgfVxuXG4gIGNvbnN0IG5hbWUgPSAodmFyRGVjbC5uYW1lIGFzIHRzLklkZW50aWZpZXIpLnRleHQ7XG5cbiAgLy8gbm9kZS5nZXRUZXh0KCkgb24gYSBuYW1lIHRoYXQgc3RhcnRzIHdpdGggdHdvIHVuZGVyc2NvcmVzIHdpbGwgcmV0dXJuIHRocmVlIGluc3RlYWQuXG4gIHJldHVybiBuYW1lLnJlcGxhY2UoL15fX18vLCAnX18nKTtcbn1cbiJdfQ== |
@@ -11,6 +11,6 @@ "use strict"; | ||
const ts = require("typescript"); | ||
const pureFunctionComment = '@__PURE__'; | ||
function getPrefixFunctionsTransformer() { | ||
return (context) => { | ||
const transformer = (sf) => { | ||
const pureFunctionComment = '@__PURE__'; | ||
const topLevelFunctions = findTopLevelFunctions(sf); | ||
@@ -55,7 +55,9 @@ const pureImports = findPureImports(sf); | ||
&& previousNode.kind === ts.SyntaxKind.ParenthesizedExpression | ||
&& node.parent) { | ||
&& node.parent | ||
&& !hasPureComment(node.parent)) { | ||
topLevelFunctions.push(node.parent); | ||
} | ||
else if (node.kind === ts.SyntaxKind.CallExpression | ||
|| node.kind === ts.SyntaxKind.NewExpression) { | ||
else if ((node.kind === ts.SyntaxKind.CallExpression | ||
|| node.kind === ts.SyntaxKind.NewExpression) | ||
&& !hasPureComment(node)) { | ||
topLevelFunctions.push(node); | ||
@@ -89,2 +91,6 @@ } | ||
exports.findPureImports = findPureImports; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHJlZml4LWZ1bmN0aW9ucy5qcyIsInNvdXJjZVJvb3QiOiIvVXNlcnMvaGFuc2wvU291cmNlcy9kZXZraXQvIiwic291cmNlcyI6WyJwYWNrYWdlcy9hbmd1bGFyX2RldmtpdC9idWlsZF9vcHRpbWl6ZXIvc3JjL3RyYW5zZm9ybXMvcHJlZml4LWZ1bmN0aW9ucy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOztBQUFBOzs7Ozs7R0FNRztBQUNILGlDQUFpQztBQUdqQztJQUNFLE1BQU0sQ0FBQyxDQUFDLE9BQWlDO1FBQ3ZDLE1BQU0sV0FBVyxHQUFrQyxDQUFDLEVBQWlCO1lBRW5FLE1BQU0sbUJBQW1CLEdBQUcsV0FBVyxDQUFDO1lBQ3hDLE1BQU0saUJBQWlCLEdBQUcscUJBQXFCLENBQUMsRUFBRSxDQUFDLENBQUM7WUFDcEQsTUFBTSxXQUFXLEdBQUcsZUFBZSxDQUFDLEVBQUUsQ0FBQyxDQUFDO1lBQ3hDLE1BQU0sa0JBQWtCLEdBQUcsd0JBQXdCLFdBQVcsQ0FBQyxJQUFJLENBQUMsR0FBRyxDQUFDLG9CQUFvQixDQUFDO1lBRTdGLE1BQU0sT0FBTyxHQUFlLENBQUMsSUFBYTtnQkFFeEMsa0RBQWtEO2dCQUNsRCxFQUFFLENBQUMsQ0FBQyxJQUFJLENBQUMsTUFBTSxJQUFJLElBQUksQ0FBQyxNQUFNLENBQUMsTUFBTSxLQUFLLFNBQVMsSUFBSSxJQUFJLENBQUMsR0FBRyxLQUFLLENBQUMsQ0FBQyxDQUFDLENBQUM7b0JBQ3RFLE1BQU0sT0FBTyxHQUFHLEVBQUUsQ0FBQywwQkFBMEIsQ0F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lSW1wb3J0cyhwYXJlbnROb2RlOiB0cy5Ob2RlKTogc3RyaW5nW10ge1xuICBjb25zdCBwdXJlSW1wb3J0czogc3RyaW5nW10gPSBbXTtcbiAgdHMuZm9yRWFjaENoaWxkKHBhcmVudE5vZGUsIGNiKTtcblxuICBmdW5jdGlvbiBjYihub2RlOiB0cy5Ob2RlKSB7XG4gICAgaWYgKG5vZGUua2luZCA9PT0gdHMuU3ludGF4S2luZC5JbXBvcnREZWNsYXJhdGlvblxuICAgICAgJiYgKG5vZGUgYXMgdHMuSW1wb3J0RGVjbGFyYXRpb24pLmltcG9ydENsYXVzZSkge1xuXG4gICAgICAvLyBTYXZlIHRoZSBwYXRoIG9mIHRoZSBpbXBvcnQgdHJhbnNmb3JtZWQgaW50byBzbmFrZSBjYXNlXG4gICAgICBjb25zdCBtb2R1bGVTcGVjaWZpZXIgPSAobm9kZSBhcyB0cy5JbXBvcnREZWNsYXJhdGlvbikubW9kdWxlU3BlY2lmaWVyIGFzIHRzLlN0cmluZ0xpdGVyYWw7XG4gICAgICBwdXJlSW1wb3J0cy5wdXNoKG1vZHVsZVNwZWNpZmllci50ZXh0LnJlcGxhY2UoL1tcXC9AXFwtXS9nLCAnXycpKTtcbiAgICB9XG5cbiAgICB0cy5mb3JFYWNoQ2hpbGQobm9kZSwgY2IpO1xuICB9XG5cbiAgcmV0dXJuIHB1cmVJbXBvcnRzO1xufVxuIl19 | ||
function hasPureComment(node) { | ||
const leadingComment = ts.getSyntheticLeadingComments(node); | ||
return leadingComment && leadingComment.some((comment) => comment.text === pureFunctionComment); | ||
} | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHJlZml4LWZ1bmN0aW9ucy5qcyIsInNvdXJjZVJvb3QiOiIvVXNlcnMvaGFuc2wvU291cmNlcy9kZXZraXQvIiwic291cmNlcyI6WyJwYWNrYWdlcy9hbmd1bGFyX2RldmtpdC9idWlsZF9vcHRpbWl6ZXIvc3JjL3RyYW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k7XG5cbiAgcmV0dXJuIGxlYWRpbmdDb21tZW50ICYmIGxlYWRpbmdDb21tZW50LnNvbWUoKGNvbW1lbnQpID0+IGNvbW1lbnQudGV4dCA9PT0gcHVyZUZ1bmN0aW9uQ29tbWVudCk7XG59XG4iXX0= |
@@ -9,3 +9,4 @@ /** | ||
import * as ts from 'typescript'; | ||
export declare function testScrubFile(content: string): boolean; | ||
export declare function getScrubFileTransformer(program: ts.Program): ts.TransformerFactory<ts.SourceFile>; | ||
export declare function expect<T extends ts.Node>(node: ts.Node, kind: ts.SyntaxKind): T; |
@@ -11,2 +11,12 @@ "use strict"; | ||
const ts = require("typescript"); | ||
const ast_utils_1 = require("../helpers/ast-utils"); | ||
function testScrubFile(content) { | ||
const markers = [ | ||
'decorators', | ||
'propDecorators', | ||
'ctorParameters', | ||
]; | ||
return markers.some((marker) => content.indexOf(marker) !== -1); | ||
} | ||
exports.testScrubFile = testScrubFile; | ||
// Don't remove `ctorParameters` from these. | ||
@@ -82,14 +92,2 @@ const platformWhitelist = [ | ||
exports.expect = expect; | ||
function collectDeepNodes(node, kind) { | ||
const nodes = []; | ||
const helper = (child) => { | ||
if (child.kind === kind) { | ||
// tslint:disable-next-line:no-any | ||
nodes.push(child); | ||
} | ||
ts.forEachChild(child, helper); | ||
}; | ||
ts.forEachChild(node, helper); | ||
return nodes; | ||
} | ||
function nameOfSpecifier(node) { | ||
@@ -104,3 +102,3 @@ return node.name && node.name.text || '<unknown>'; | ||
if (isAngularCoreImport(importDecl)) { | ||
specs.push(...collectDeepNodes(node, ts.SyntaxKind.ImportSpecifier) | ||
specs.push(...ast_utils_1.collectDeepNodes(node, ts.SyntaxKind.ImportSpecifier) | ||
.filter((spec) => isAngularCoreSpecifier(spec))); | ||
@@ -295,2 +293,2 @@ } | ||
} | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2NydWItZmlsZS5qcyIsInNvdXJjZVJvb3QiOiIvVXNlcnMvaGFuc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XG4gIH1cbiAgY29uc3QgbmFtZSA9IGFzc2lnbm1lbnQubmFtZSBhcyB0cy5JZGVudGlmaWVyO1xuXG4gIHJldHVybiBuYW1lLnRleHQgPT09ICd0eXBlJztcbn1cblxuLy8gQ2hlY2sgaWYgYW4gaWRlbnRpZmllciBpcyBwYXJ0IG9mIHRoZSBrbm93biBBbmd1bGFyIE1ldGFkYXRhLlxuZnVuY3Rpb24gaWRlbnRpZmllcklzTWV0YWRhdGEoXG4gIGlkOiB0cy5JZGVudGlmaWVyLFxuICBtZXRhZGF0YTogdHMuTm9kZVtdLFxuICBjaGVja2VyOiB0cy5UeXBlQ2hlY2tlcixcbik6IGJvb2xlYW4ge1xuICBjb25zdCBzeW1ib2wgPSBjaGVja2VyLmdldFN5bWJvbEF0TG9jYXRpb24oaWQpO1xuICBpZiAoIXN5bWJvbCB8fCAhc3ltYm9sLmRlY2xhcmF0aW9ucyB8fCAhc3ltYm9sLmRlY2xhcmF0aW9ucy5sZW5ndGgpIHtcbiAgICByZXR1cm4gZmFsc2U7XG4gIH1cblxuICByZXR1cm4gc3ltYm9sXG4gICAgLmRlY2xhcmF0aW9uc1xuICAgIC5zb21lKChzcGVjKSA9PiBtZXRhZGF0YS5pbmRleE9mKHNwZWMpICE9PSAtMSk7XG59XG4iXX0= |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
218436
34
1555
195