ESLint: Re-enable rule no-unused-vars (#10865)

* Re-enable rule no-unused-vars

* fixup! Re-enable rule no-unused-vars
This commit is contained in:
Kamil Gabryjelski 2020-09-15 00:42:06 +02:00 committed by GitHub
parent e28f3d6220
commit 01f90107e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 15 additions and 17 deletions

View File

@ -60,7 +60,6 @@ module.exports = {
'@typescript-eslint/no-empty-function': 0, '@typescript-eslint/no-empty-function': 0,
'@typescript-eslint/no-explicit-any': 0, '@typescript-eslint/no-explicit-any': 0,
'@typescript-eslint/no-use-before-define': 1, // disabled temporarily '@typescript-eslint/no-use-before-define': 1, // disabled temporarily
'@typescript-eslint/no-unused-vars': 0, // disabled temporarily
'@typescript-eslint/explicit-function-return-type': 0, '@typescript-eslint/explicit-function-return-type': 0,
'@typescript-eslint/explicit-module-boundary-types': 0, // re-enable up for discussion '@typescript-eslint/explicit-module-boundary-types': 0, // re-enable up for discussion
camelcase: 0, camelcase: 0,

View File

@ -39,7 +39,6 @@ export interface MenuObjectProps {
export default function MenuObject({ export default function MenuObject({
label, label,
icon,
childs, childs,
url, url,
index, index,

View File

@ -60,21 +60,6 @@ export type WrapperProps = InternalProps & {
animation?: boolean; // for the modal animation?: boolean; // for the modal
}; };
export default function PropertiesModalWrapper({
show,
onHide,
animation,
slice,
onSave,
}: WrapperProps) {
// The wrapper is a separate component so that hooks only run when the modal opens
return (
<Modal show={show} onHide={onHide} animation={animation} bsSize="large">
<PropertiesModal slice={slice} onHide={onHide} onSave={onSave} />
</Modal>
);
}
function PropertiesModal({ slice, onHide, onSave }: InternalProps) { function PropertiesModal({ slice, onHide, onSave }: InternalProps) {
const [submitting, setSubmitting] = useState(false); const [submitting, setSubmitting] = useState(false);
const errorDialog = useRef<any>(null); const errorDialog = useRef<any>(null);
@ -279,3 +264,18 @@ function PropertiesModal({ slice, onHide, onSave }: InternalProps) {
</form> </form>
); );
} }
export default function PropertiesModalWrapper({
show,
onHide,
animation,
slice,
onSave,
}: WrapperProps) {
// The wrapper is a separate component so that hooks only run when the modal opens
return (
<Modal show={show} onHide={onHide} animation={animation} bsSize="large">
<PropertiesModal slice={slice} onHide={onHide} onSave={onSave} />
</Modal>
);
}