Fix type errors, use () => RootState for getState

Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
This commit is contained in:
marcin mikołajczak
2022-06-18 11:51:02 +02:00
parent 47b67df323
commit ee55241792
18 changed files with 61 additions and 50 deletions

View File

@ -3,7 +3,7 @@ import { MessageDescriptor, useIntl } from 'react-intl';
import { Button, Form, FormActions, Text } from 'soapbox/components/ui';
import { useAppDispatch } from 'soapbox/hooks';
import { AppDispatch } from 'soapbox/store';
import { AppDispatch, RootState } from 'soapbox/store';
interface ICSVExporter {
messages: {
@ -11,7 +11,7 @@ interface ICSVExporter {
input_hint: MessageDescriptor,
submit: MessageDescriptor,
},
action: () => (dispatch: AppDispatch, getState: any) => Promise<void>,
action: () => (dispatch: AppDispatch, getState: () => RootState) => Promise<void>,
}
const CSVExporter: React.FC<ICSVExporter> = ({ messages, action }) => {