diff --git a/landing/competitor-feature.react.js b/landing/competitor-feature.react.js --- a/landing/competitor-feature.react.js +++ b/landing/competitor-feature.react.js @@ -13,8 +13,8 @@ function useDescriptionContent( description: string | $ReadOnlyArray, - descriptionClassName, - descriptionMultiClassName, + descriptionClassName: string, + descriptionMultiClassName: string, ) { return React.useMemo(() => { if (typeof description === 'string') { diff --git a/landing/investor-profile.react.js b/landing/investor-profile.react.js --- a/landing/investor-profile.react.js +++ b/landing/investor-profile.react.js @@ -49,7 +49,10 @@ css.involvement, ]); - const stopPropagation = React.useCallback(e => e.stopPropagation(), []); + const stopPropagation = React.useCallback( + (e: SyntheticEvent) => e.stopPropagation(), + [], + ); let websiteIcon; if (website) { diff --git a/landing/keyserver-faq.react.js b/landing/keyserver-faq.react.js --- a/landing/keyserver-faq.react.js +++ b/landing/keyserver-faq.react.js @@ -15,7 +15,7 @@ css.questionText, ]); - const [activeFAQIndex, setActiveFAQIndex] = React.useState(null); + const [activeFAQIndex, setActiveFAQIndex] = React.useState(null); const onClickFAQItem = React.useCallback( (index: number) => { diff --git a/landing/keyservers.react.js b/landing/keyservers.react.js --- a/landing/keyservers.react.js +++ b/landing/keyservers.react.js @@ -51,7 +51,7 @@ }); }, []); - const [eyeNode, setEyeNode] = React.useState(null); + const [eyeNode, setEyeNode] = React.useState(null); useIsomorphicLayoutEffect(() => { if (!eyeNode) { return undefined; @@ -60,7 +60,7 @@ return () => eyeNode.removeEventListener('load', onEyeIllustrationLoad); }, [eyeNode, onEyeIllustrationLoad]); - const [cloudNode, setCloudNode] = React.useState(null); + const [cloudNode, setCloudNode] = React.useState(null); useIsomorphicLayoutEffect(() => { if (!cloudNode) { return undefined; diff --git a/landing/subscription-form.react.js b/landing/subscription-form.react.js --- a/landing/subscription-form.react.js +++ b/landing/subscription-form.react.js @@ -1,6 +1,7 @@ // @flow import classNames from 'classnames'; +import invariant from 'invariant'; import * as React from 'react'; import { validEmailRegex } from 'lib/shared/account-utils.js'; @@ -83,9 +84,14 @@ const buttonClassName = classNames([typography.paragraph2, btnStyle]); const errorTextClassName = classNames([typography.paragraph2, css.errorText]); - const onEmailChange = React.useCallback(e => { - setEmail(e.target.value); - }, []); + const onEmailChange = React.useCallback( + (e: SyntheticEvent) => { + const { target } = e; + invariant(target instanceof HTMLInputElement, 'target not input'); + setEmail(target.value); + }, + [], + ); let errorText; if (subscriptionFormStatus.status === 'error') {