Implemented strict mode for the project (broken tests, hundreds of @ts-ignore and new errors are included) [skip ci]

This commit is contained in:
ErickSkrauch
2020-01-17 23:37:52 +03:00
committed by SleepWalker
parent 10e8b77acf
commit 96049ad4ad
151 changed files with 2470 additions and 1869 deletions

View File

@@ -1,17 +1,28 @@
import { Action as ReduxPopup } from 'redux';
import { PopupConfig } from './reducer';
export const POPUP_CREATE = 'POPUP_CREATE';
export function create(payload: PopupConfig) {
return {
type: POPUP_CREATE,
payload,
};
interface PopupCreateAction extends ReduxPopup {
type: 'POPUP_CREATE';
payload: PopupConfig;
}
export const POPUP_DESTROY = 'POPUP_DESTROY';
export function destroy(popup: PopupConfig) {
export function create(popup: PopupConfig): PopupCreateAction {
return {
type: POPUP_DESTROY,
type: 'POPUP_CREATE',
payload: popup,
};
}
interface PopupDestroyAction extends ReduxPopup {
type: 'POPUP_DESTROY';
payload: PopupConfig;
}
export function destroy(popup: PopupConfig): PopupDestroyAction {
return {
type: 'POPUP_DESTROY',
payload: popup,
};
}
export type Action = PopupCreateAction | PopupDestroyAction;