aboutsummaryrefslogtreecommitdiff
path: root/node_modules/tslint/lib/rules/radixRule.js
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/tslint/lib/rules/radixRule.js')
-rw-r--r--node_modules/tslint/lib/rules/radixRule.js26
1 files changed, 13 insertions, 13 deletions
diff --git a/node_modules/tslint/lib/rules/radixRule.js b/node_modules/tslint/lib/rules/radixRule.js
index 13daded51..63907bec5 100644
--- a/node_modules/tslint/lib/rules/radixRule.js
+++ b/node_modules/tslint/lib/rules/radixRule.js
@@ -28,21 +28,21 @@ var Rule = (function (_super) {
Rule.prototype.apply = function (sourceFile) {
return this.applyWithFunction(sourceFile, walk);
};
+ /* tslint:disable:object-literal-sort-keys */
+ Rule.metadata = {
+ ruleName: "radix",
+ description: "Requires the radix parameter to be specified when calling `parseInt`.",
+ rationale: (_a = ["\n From [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/parseInt):\n > Always specify this parameter to eliminate reader confusion and to guarantee predictable behavior.\n > Different implementations produce different results when a radix is not specified, usually defaulting the value to 10."], _a.raw = ["\n From [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/parseInt):\n > Always specify this parameter to eliminate reader confusion and to guarantee predictable behavior.\n > Different implementations produce different results when a radix is not specified, usually defaulting the value to 10."], Lint.Utils.dedent(_a)),
+ optionsDescription: "Not configurable.",
+ options: null,
+ optionExamples: [true],
+ type: "functionality",
+ typescriptOnly: false,
+ };
+ /* tslint:enable:object-literal-sort-keys */
+ Rule.FAILURE_STRING = "Missing radix parameter";
return Rule;
}(Lint.Rules.AbstractRule));
-/* tslint:disable:object-literal-sort-keys */
-Rule.metadata = {
- ruleName: "radix",
- description: "Requires the radix parameter to be specified when calling `parseInt`.",
- rationale: (_a = ["\n From [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/parseInt):\n > Always specify this parameter to eliminate reader confusion and to guarantee predictable behavior.\n > Different implementations produce different results when a radix is not specified, usually defaulting the value to 10."], _a.raw = ["\n From [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/parseInt):\n > Always specify this parameter to eliminate reader confusion and to guarantee predictable behavior.\n > Different implementations produce different results when a radix is not specified, usually defaulting the value to 10."], Lint.Utils.dedent(_a)),
- optionsDescription: "Not configurable.",
- options: null,
- optionExamples: [true],
- type: "functionality",
- typescriptOnly: false,
-};
-/* tslint:enable:object-literal-sort-keys */
-Rule.FAILURE_STRING = "Missing radix parameter";
exports.Rule = Rule;
function walk(ctx) {
return ts.forEachChild(ctx.sourceFile, function cb(node) {