Skip to content

Commit 813a34d

Browse files
authored
infra(unicorn): prefer-negative-index (#2512)
1 parent 48a7af4 commit 813a34d

2 files changed

Lines changed: 1 addition & 2 deletions

File tree

.eslintrc.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ module.exports = defineConfig({
5959
'unicorn/prefer-code-point': 'off',
6060
'unicorn/prefer-export-from': 'off',
6161
'unicorn/prefer-module': 'off',
62-
'unicorn/prefer-negative-index': 'off',
6362
'unicorn/prefer-string-slice': 'off',
6463
'unicorn/prevent-abbreviations': 'off',
6564
'unicorn/require-array-join-separator': 'off',

scripts/apidoc/signature.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ function extractDefaultFromComment(comment?: Comment): string | undefined {
342342
throw new Error(`Found description text after the default value:\n${text}`);
343343
}
344344

345-
summary.splice(summary.length - 2, 2);
345+
summary.splice(-2, 2);
346346
const lastSummaryPart = summary[summary.length - 1];
347347
lastSummaryPart.text = lastSummaryPart.text.replace(/[ \n]Defaults to $/, '');
348348
return result[2];

0 commit comments

Comments
 (0)