eslint-community / eslint-plugin-promise

Enforce best practices for JavaScript promises
ISC License
939 stars 91 forks source link

Access to `Promise` methods in a way different from dot trigger `spec-only` #534

Open zloirock opened 1 month ago

zloirock commented 1 month ago
Promise['all'];  // error  Avoid using non-standard 'Promise.undefined'  promise/spec-only
var method = 'all';
Promise[method]; // error  Avoid using non-standard 'Promise.method'     promise/spec-only
zloirock commented 1 month ago

Unlike #533, it can't be worked around by adding undefined or something like that to allowedMethods.