diff --git a/.eslintrc.js b/.eslintrc.js index 586633ece..395e4e03c 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -34,5 +34,13 @@ module.exports = { 'react/require-default-props': OFF, 'no-nested-ternary': OFF, 'no-irregular-whitespace': OFF, + '@typescript-eslint/no-unused-vars': [ + 'error', + { + argsIgnorePattern: '^_', + varsIgnorePattern: '^_', + caughtErrorsIgnorePattern: '^_', + }, + ], }, }; diff --git a/src/components/FeaturePanel/renderers/OpeningHoursRenderer.tsx b/src/components/FeaturePanel/renderers/OpeningHoursRenderer.tsx index 7d5449b3a..6c713ed3b 100644 --- a/src/components/FeaturePanel/renderers/OpeningHoursRenderer.tsx +++ b/src/components/FeaturePanel/renderers/OpeningHoursRenderer.tsx @@ -61,7 +61,7 @@ const formatDescription = (isOpen: boolean, days: SimpleOpeningHoursTable) => { const OpeningHoursRenderer = ({ v }) => { const [isExpanded, toggle] = useToggleState(false); const { daysTable, isOpen } = parseOpeningHours(v); - const { ph, ...days } = daysTable; + const { ph, ...days } = daysTable; // eslint-disable-line @typescript-eslint/no-unused-vars const timesByDay = Object.values(days).map((times, idx) => ({ times, day: weekDays[idx], diff --git a/src/components/SearchBox/AutocompleteInput.tsx b/src/components/SearchBox/AutocompleteInput.tsx index b95aa17ca..5bb2b0d61 100644 --- a/src/components/SearchBox/AutocompleteInput.tsx +++ b/src/components/SearchBox/AutocompleteInput.tsx @@ -31,7 +31,6 @@ const useFocusOnSlash = () => { const SearchBoxInput = ({ params, setInputValue, autocompleteRef }) => { const inputRef = useFocusOnSlash(); - const { InputLabelProps, InputProps, ...restParams } = params; useEffect(() => { // @ts-ignore @@ -43,7 +42,7 @@ const SearchBoxInput = ({ params, setInputValue, autocompleteRef }) => { return ( { tags = {}, lat, lon, - nodes, members, osmappDeletedMarker, ...osmMeta