change a few typings

This commit is contained in:
David Sevilla Martin 2020-03-15 09:40:45 -04:00
parent e86940b6a3
commit 9b83159be5
No known key found for this signature in database
GPG Key ID: F764F1417E16B15F
2 changed files with 4 additions and 4 deletions

View File

@ -1,4 +1,4 @@
import Mithril from 'mithril'; import Mithril, { ClassComponent } from 'mithril';
export type ComponentProps = { export type ComponentProps = {
children?: Mithril.Children; children?: Mithril.Children;
@ -8,8 +8,8 @@ export type ComponentProps = {
[key: string]: any; [key: string]: any;
}; };
export default class Component<T extends ComponentProps = any> { export default class Component<T extends ComponentProps = any> implements ClassComponent {
element: HTMLElement; element!: HTMLElement;
props: T; props: T;

View File

@ -23,7 +23,7 @@ export default class Forum extends Application {
*/ */
cache: { cache: {
notifications?: Notification[][]; notifications?: Notification[][];
discussionList?: DiscussionList; discussionList?: DiscussionList | null;
[key: string]: any; [key: string]: any;
} = {}; } = {};