Currently eslint turns nearly every JS file in Drupal 9 red, as ES6 isn't yet allowed directly. With Drupal 10 ES6 will be the new standard, as old browsers are dropped.
To fix this in Drupal 9, we'd have to use
{
"extends": "./core/.eslintrc.legacy.json"
}
instead of the default
{
"extends": "./core/.eslintrc.json"
}
in .eslintrc.json in the project folder.
I guess it's okay to do this manually, when ever it's needed or is there an easy way to override it automatically using DDEV? For Drupal 9 the legacy variant would be the correct one.
Currently eslint turns nearly every JS file in Drupal 9 red, as ES6 isn't yet allowed directly. With Drupal 10 ES6 will be the new standard, as old browsers are dropped.
To fix this in Drupal 9, we'd have to use
instead of the default
in .eslintrc.json in the project folder.
I guess it's okay to do this manually, when ever it's needed or is there an easy way to override it automatically using DDEV? For Drupal 9 the legacy variant would be the correct one.
For Drupal 10 we don't need to do this.