aboutsummaryrefslogtreecommitdiff
path: root/node_modules/tslint/lib/rules/noTrailingWhitespaceRule.js
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2017-08-14 05:01:11 +0200
committerFlorian Dold <florian.dold@gmail.com>2017-08-14 05:02:09 +0200
commit363723fc84f7b8477592e0105aeb331ec9a017af (patch)
tree29f92724f34131bac64d6a318dd7e30612e631c7 /node_modules/tslint/lib/rules/noTrailingWhitespaceRule.js
parent5634e77ad96bfe1818f6b6ee70b7379652e5487f (diff)
node_modules
Diffstat (limited to 'node_modules/tslint/lib/rules/noTrailingWhitespaceRule.js')
-rw-r--r--node_modules/tslint/lib/rules/noTrailingWhitespaceRule.js48
1 files changed, 24 insertions, 24 deletions
diff --git a/node_modules/tslint/lib/rules/noTrailingWhitespaceRule.js b/node_modules/tslint/lib/rules/noTrailingWhitespaceRule.js
index 56615b1b5..b29aec663 100644
--- a/node_modules/tslint/lib/rules/noTrailingWhitespaceRule.js
+++ b/node_modules/tslint/lib/rules/noTrailingWhitespaceRule.js
@@ -37,32 +37,32 @@ var Rule = (function (_super) {
ignoreTemplates: this.ruleArguments.indexOf(OPTION_IGNORE_TEMPLATE_STRINGS) !== -1,
});
};
+ /* tslint:disable:object-literal-sort-keys */
+ Rule.metadata = {
+ ruleName: "no-trailing-whitespace",
+ description: "Disallows trailing whitespace at the end of a line.",
+ rationale: "Keeps version control diffs clean as it prevents accidental whitespace from being committed.",
+ optionsDescription: (_a = ["\n Possible settings are:\n\n * `\"", "\"`: Allows trailing whitespace in template strings.\n * `\"", "\"`: Allows trailing whitespace in comments.\n * `\"", "\"`: Allows trailing whitespace only in JSDoc comments."], _a.raw = ["\n Possible settings are:\n\n * \\`\"", "\"\\`: Allows trailing whitespace in template strings.\n * \\`\"", "\"\\`: Allows trailing whitespace in comments.\n * \\`\"", "\"\\`: Allows trailing whitespace only in JSDoc comments."], Lint.Utils.dedent(_a, OPTION_IGNORE_TEMPLATE_STRINGS, OPTION_IGNORE_COMMENTS, OPTION_IGNORE_JSDOC)),
+ hasFix: true,
+ options: {
+ type: "array",
+ items: {
+ type: "string",
+ enum: [OPTION_IGNORE_COMMENTS, OPTION_IGNORE_JSDOC, OPTION_IGNORE_TEMPLATE_STRINGS],
+ },
+ },
+ optionExamples: [
+ true,
+ [true, OPTION_IGNORE_COMMENTS],
+ [true, OPTION_IGNORE_JSDOC],
+ ],
+ type: "style",
+ typescriptOnly: false,
+ };
+ /* tslint:enable:object-literal-sort-keys */
+ Rule.FAILURE_STRING = "trailing whitespace";
return Rule;
}(Lint.Rules.AbstractRule));
-/* tslint:disable:object-literal-sort-keys */
-Rule.metadata = {
- ruleName: "no-trailing-whitespace",
- description: "Disallows trailing whitespace at the end of a line.",
- rationale: "Keeps version control diffs clean as it prevents accidental whitespace from being committed.",
- optionsDescription: (_a = ["\n Possible settings are:\n\n * `\"", "\"`: Allows trailing whitespace in template strings.\n * `\"", "\"`: Allows trailing whitespace in comments.\n * `\"", "\"`: Allows trailing whitespace only in JSDoc comments."], _a.raw = ["\n Possible settings are:\n\n * \\`\"", "\"\\`: Allows trailing whitespace in template strings.\n * \\`\"", "\"\\`: Allows trailing whitespace in comments.\n * \\`\"", "\"\\`: Allows trailing whitespace only in JSDoc comments."], Lint.Utils.dedent(_a, OPTION_IGNORE_TEMPLATE_STRINGS, OPTION_IGNORE_COMMENTS, OPTION_IGNORE_JSDOC)),
- hasFix: true,
- options: {
- type: "array",
- items: {
- type: "string",
- enum: [OPTION_IGNORE_COMMENTS, OPTION_IGNORE_JSDOC, OPTION_IGNORE_TEMPLATE_STRINGS],
- },
- },
- optionExamples: [
- true,
- [true, OPTION_IGNORE_COMMENTS],
- [true, OPTION_IGNORE_JSDOC],
- ],
- type: "style",
- typescriptOnly: false,
-};
-/* tslint:enable:object-literal-sort-keys */
-Rule.FAILURE_STRING = "trailing whitespace";
exports.Rule = Rule;
function walk(ctx) {
var possibleFailures = [];