diff options
| -rw-r--r-- | gui/.eslintrc.js | 2 | ||||
| -rw-r--r-- | gui/src/renderer/components/LocationList.tsx | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/gui/.eslintrc.js b/gui/.eslintrc.js index 66948d120e..02e377d84a 100644 --- a/gui/.eslintrc.js +++ b/gui/.eslintrc.js @@ -91,10 +91,10 @@ module.exports = { 'no-return-await': 'error', 'react/jsx-no-bind': 'error', '@typescript-eslint/naming-convention': ['error', ...namingConvention], + '@typescript-eslint/ban-ts-comment': ['error', { 'ts-ignore': false }], '@typescript-eslint/no-use-before-define': 'off', '@typescript-eslint/explicit-module-boundary-types': 'off', '@typescript-eslint/no-non-null-assertion': 'off', - '@typescript-eslint/ban-ts-comment': 'off', }, }; diff --git a/gui/src/renderer/components/LocationList.tsx b/gui/src/renderer/components/LocationList.tsx index 2f2b440dfc..2f8d44048e 100644 --- a/gui/src/renderer/components/LocationList.tsx +++ b/gui/src/renderer/components/LocationList.tsx @@ -124,8 +124,9 @@ export default class LocationList<SpecialValueType> extends React.Component< if (typeof this.props.selectedElementRef === 'function') { this.props.selectedElementRef(value); } else { - // @ts-ignore - this.props.selectedElementRef.current = value; + const ref = this.props + .selectedElementRef as React.MutableRefObject<React.ReactInstance | null>; + ref.current = value; } } } |
