build: enhance tsconfig type check (#2732)

(cherry picked from commit b383ce36cd)
This commit is contained in:
Himself65
2023-06-09 01:42:58 +08:00
committed by himself65
parent d9c67e4723
commit 62caa555de
34 changed files with 111 additions and 68 deletions
@@ -30,7 +30,7 @@ export class AffineErrorBoundary extends Component<
AffineErrorBoundaryProps,
AffineErrorBoundaryState
> {
public state: AffineErrorBoundaryState = {
public override state: AffineErrorBoundaryState = {
error: null,
};
@@ -40,11 +40,11 @@ export class AffineErrorBoundary extends Component<
return { error };
}
public componentDidCatch(error: AffineError, errorInfo: ErrorInfo) {
public override componentDidCatch(error: AffineError, errorInfo: ErrorInfo) {
console.error('Uncaught error:', error, errorInfo);
}
public render(): ReactNode {
public override render(): ReactNode {
if (this.state.error) {
const error = this.state.error;
if (error instanceof PageNotFoundError) {
@@ -80,6 +80,7 @@ const PageListEmpty = (props: {
if (listType === 'shared') {
return t['emptySharedPages']();
}
return;
};
return (