Skip to content

Commit

Permalink
chore(deps): update all eslint related dependencies and fix new errors
Browse files Browse the repository at this point in the history
  • Loading branch information
gaetanmaisse authored and gcusnieux committed Jun 14, 2021
1 parent 3b8d43c commit 9328f5b
Show file tree
Hide file tree
Showing 6 changed files with 33 additions and 49 deletions.
1 change: 1 addition & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ module.exports = {
'space-before-function-paren': 'off',
quotes: ['error', 'single', { allowTemplateLiterals: true, avoidEscape: true }],
semi: ['error', 'always'],
'accessor-pairs': 'off',
},
globals: {
Event: 'readonly',
Expand Down
56 changes: 24 additions & 32 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,12 @@
"chromatic": "5.9.0",
"del": "6.0.0",
"eslint": "7.28.0",
"eslint-config-prettier": "7.2.0",
"eslint-config-standard": "14.1.1",
"eslint-config-prettier": "8.3.0",
"eslint-config-standard": "16.0.3",
"eslint-plugin-import": "2.23.4",
"eslint-plugin-lit": "1.5.1",
"eslint-plugin-node": "10.0.0",
"eslint-plugin-promise": "4.3.1",
"eslint-plugin-node": "11.1.0",
"eslint-plugin-promise": "5.1.0",
"eslint-plugin-standard": "4.1.0",
"esm": "3.2.25",
"fs-extra": "8.1.0",
Expand Down
14 changes: 2 additions & 12 deletions src/organisms/gv-resources.js
Original file line number Diff line number Diff line change
Expand Up @@ -168,12 +168,7 @@ export class GvResources extends KeyboardElement(LitElement) {
};

if (detail.values._id != null) {
let index = -1;
this.resources.find((r, i) => {
if (r._id === resource._id) {
index = i;
}
});
const index = this.resources.findIndex((r) => r._id === resource._id);
this.resources[index] = { ...this.resources[index], ...resource };
} else {
if (this.resources == null) {
Expand Down Expand Up @@ -251,12 +246,7 @@ export class GvResources extends KeyboardElement(LitElement) {
}

_onChangeResourceState(item, event) {
let index = null;
this.resources.find((r, i) => {
if (r._id === item._id) {
index = i;
}
});
const index = this.resources.find((r) => r._id === item._id);
this.resources[index] = { ...this.resources[index], enabled: item.enabled };
dispatchCustomEvent(this, 'change', { resources: this.resources });
}
Expand Down
1 change: 1 addition & 0 deletions stories/lib/make-story.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ export function makeStory(...configs) {
const variableName = '${' + name + '}';
return `.${name}='${variableName}'`;
}
return null;
})
.filter((a) => a != null);

Expand Down
2 changes: 1 addition & 1 deletion tasks/check-i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ async function run() {

function getDeepKeys(obj) {
let keys = [];
for (var key in obj) {
for (const key in obj) {
if (typeof obj[key] === 'object') {
const subkeys = getDeepKeys(obj[key]);
keys = keys.concat(
Expand Down

0 comments on commit 9328f5b

Please sign in to comment.