Skip to content

Latest commit

 

History

History
 
 

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

ESLint Rules

Project-specific ESLint rules.

Usage

var rules = require( '@stdlib/_tools/eslint/rules' );

rules

Project-specific ESLint rules.

var eslint = rules;
// returns {...}

General Rules

  • capitalized-comments: ESLint rule to enforce that comments start with an uppercase letter.
  • doctest-annotation-spacing: ESLint rule to enforce spacing in return annotations in single-line comments.
  • doctest-marker: ESLint rule to enforce marker style conventions for return annotations.
  • doctest-quote-props: ESLint rule to enforce that property names in return annotations are quoted using single quotes.
  • doctest: ESLint rule to ensure return annotations match the actual output.
  • empty-line-before-comment: ESLint rule to enforce empty lines before comments.
  • eol-open-bracket-spacing: ESLint rule to enforce that no spaces are present between an opening parenthesis or bracket and a nested object or array expression at the end of a line.
  • first-unit-test: ESLint rule to enforce that a tape file starts with the expected test.
  • line-closing-bracket-spacing: ESLint rule to enforce that no spaces are present between a closing parenthesis or bracket and a nested object or array expression at the beginning of a line.
  • module-exports-last: ESLint rule enforcing that export statements appear at the end of a file.
  • namespace-export-all: ESLint rule to enforce that a namespace index.js exports all packages in the respective namespace directory.
  • namespace-index-order: ESLint rule to enforce that modules in a namespace index.js file are listed in alphabetical order according to module name.
  • new-cap-array: ESLint rule enforcing that the Array constructor is invoked with the new keyword.
  • new-cap-error: ESLint rule enforcing that error constructors are invoked with the new keyword.
  • new-cap-regexp: ESLint rule enforcing that the RegExp constructor is invoked with the new keyword.
  • no-bench-string-concat: ESLint rule enforcing that @stdlib/string/format is used instead of string concatenation in benchmark descriptions.
  • no-builtin-big-int: ESLint rule disallowing the use of the built-in global BigInt literal syntax and constructor.
  • no-builtin-math: ESLint rule enforcing that stdlib equivalents are used instead of the built-in global Math object.
  • no-dynamic-exports: ESLint rule enforcing that only statically analyzable values are exported.
  • no-dynamic-require: ESLint rule enforcing that require() calls have only string literals as arguments.
  • no-empty-comments: ESLint rule to disallow empty comments.
  • no-empty-lines-between-requires: ESLint rule to enforce no empty lines between module-level require statements.
  • no-error-string-concat: ESLint rule disallowing string concatenation in error messages.
  • no-immediate-require: ESLint rule enforcing that require() expressions are not immediately invoked.
  • no-internal-require: ESLint rule disallowing require() calls into internals of another stdlib package.
  • no-multiple-empty-lines: ESLint rule to enforce that code does not contain multiple blank lines.
  • no-nested-require: ESLint rule enforcing that one does not use nested property access for require() expressions.
  • no-new-array: ESLint rule disallowing the use of the new Array() constructor.
  • no-redeclare: ESLint rule disallowing variable redeclarations.
  • no-require-absolute-path: ESLint rule disallowing require() statements containing absolute file paths.
  • no-require-index: ESLint rule disallowing require() calls which explicitly require index.<ext> files.
  • no-self-require: ESLint rule enforcing that modules do not require themselves.
  • no-unassigned-require: ESLint rule forbidding unassigned require statements.
  • no-unnecessary-nested-functions: ESLint rule to prevent unnecessary function nesting when inner functions don't depend on outer scope variables.
  • repl-namespace-order: ESLint rule to enforce that packages are added to a REPL namespace object in alphabetical order according to alias (namespace key).
  • require-file-extensions: ESLint rule enforcing that require() calls of files end with a whitelisted file extension.
  • require-globals: ESLint rule enforcing that specified global variables are explicitly required.
  • require-last-path-relative: ESLint rule enforcing that the last require statement is a relative path.
  • require-leading-slash: ESLint rule disallowing require() calls of relative paths which do not begin with a leading ./.
  • require-order: ESLint rule enforcing a specified order of require() calls.
  • require-spaces: ESLint rule enforcing spaces in require() statements.
  • section-header-empty-lines: ESLint rule to enforce that section header comments are padded by empty lines.
  • section-headers: ESLint rule to enforce formatting of section header comments.
  • ternary-condition-parentheses: ESLint rule requiring parentheses around ternary conditions.
  • tsdoc-declarations-doctest: ESLint rule to ensure that return annotations in TSDoc examples match the actual output in TypeScript declaration files (*.d.ts).
  • uppercase-required-constants: ESLint rule enforcing that required stdlib constants have uppercase variable names.
  • vars-order: ESLint rule enforcing variable declarations inside of functions to be ordered by length.

JSDoc-specific Rules

Examples

var getKeys = require( '@stdlib/utils/keys' );
var rules = require( '@stdlib/_tools/eslint/rules' );

console.log( getKeys( rules ) );