mirror of
https://github.com/nodejs/node.git
synced 2024-11-24 12:10:08 +01:00
cef144421c
I added a new custom ESLint rule to fix these problems. We have a lot of replaceable codes with primordials. Accessing built-in objects is restricted by existing rule (no-restricted-globals), but accessing property in the built-in objects is not restricted right now. We manually review codes that can be replaced by primordials, but there's a lot of code that actually needs to be fixed. We have often made pull requests to replace the primordials with. Restrict accessing global built-in objects such as `Promise`. Restrict calling static methods such as `Array.from` or `Symbol.for`. Don't restrict prototype methods to prevent false-positive. PR-URL: https://github.com/nodejs/node/pull/35448 Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com> Reviewed-By: Ben Coe <bencoe@gmail.com> |
||
---|---|---|
.. | ||
alphabetize-errors.js | ||
async-iife-no-unused-result.js | ||
crypto-check.js | ||
documented-errors.js | ||
eslint-check.js | ||
inspector-check.js | ||
lowercase-name-for-primitive.js | ||
no-duplicate-requires.js | ||
no-unescaped-regexp-dot.js | ||
non-ascii-character.js | ||
prefer-assert-iferror.js | ||
prefer-assert-methods.js | ||
prefer-common-mustnotcall.js | ||
prefer-common-mustsucceed.js | ||
prefer-primordials.js | ||
prefer-util-format-errors.js | ||
require-common-first.js | ||
required-modules.js | ||
rules-utils.js |