Skip to content

es-x/no-subclassing-builtins

disallow the subclassing of the built-in classes

This rule reports ES2015 subclassing of built-in classes as errors.

The built-in classes include the following classes (constructors):

  • Array
  • Boolean
  • Error
  • RegExp
  • Function
  • Map
  • Number
  • Promise
  • Set
  • String

💡 Examples

⛔ Examples of incorrect code for this rule:

Now loading...

🚀 Version

This rule was introduced in eslint-plugin-es v1.2.0.

📚 References