This eslint plugin is gaining popularity. The idea is to customize the rules based on the target browsers, warning when the user attempts to use a feature that is not present across the board for the entire support matrix, unless it has been polyfilled.
Examples of those include:
This issue intends to be a placeholder to discuss wether we want to bake this into this plugin or develop it as a separate addon, and track its implementation if needed.
The text was updated successfully, but these errors were encountered:
Configuration for rule "compat/compat" is invalid:
Value "last 2 Edge versions,last 2 Chrome versions,last 2 Firefox versions,last 2 Safari versions,last 2 iOS versions,last 2 ChromeAndroid versions" should NOT have more than 0 items.
Couldn't get eslint-plugin-compat to accept the browser targets via the rule and I'm not sure it currently supports that option. However, it does support specifying the targets in eslintrc using settings! Also had to provide a relative path for the require too.