mirror of
https://github.com/elyby/accounts-frontend.git
synced 2025-05-31 14:11:58 +05:30
chore(build): enable support for ts declare fields
This commit is contained in:
committed by
ErickSkrauch
parent
f7b0c10ba9
commit
79ff3b9410
@@ -15,7 +15,7 @@ class BaseAuthBody extends React.Component<
|
||||
RouteComponentProps<Record<string, any>>
|
||||
> {
|
||||
static contextType = Context;
|
||||
/* TODO: use declare */ context: React.ContextType<typeof Context>;
|
||||
declare context: React.ContextType<typeof Context>;
|
||||
prevErrors: AuthContext['auth']['error'];
|
||||
|
||||
autoFocusField: string | null = '';
|
||||
|
@@ -17,7 +17,7 @@ export default class MfaDisable extends React.Component<
|
||||
}
|
||||
> {
|
||||
static contextType = Context;
|
||||
/* TODO: use declare */ context: React.ContextType<typeof Context>;
|
||||
declare context: React.ContextType<typeof Context>;
|
||||
|
||||
state = {
|
||||
showForm: false,
|
||||
|
@@ -41,7 +41,7 @@ interface State {
|
||||
|
||||
export default class MfaEnable extends React.PureComponent<Props, State> {
|
||||
static contextType = Context;
|
||||
/* TODO: use declare */ context: React.ContextType<typeof Context>;
|
||||
declare context: React.ContextType<typeof Context>;
|
||||
|
||||
static defaultProps = {
|
||||
confirmationForm: new FormModel(),
|
||||
|
@@ -18,7 +18,7 @@ interface Props extends RouteComponentProps<RouteParams> {
|
||||
|
||||
class ChangeEmailPage extends React.Component<Props> {
|
||||
static contextType = Context;
|
||||
/* TODO: use declare */ context: React.ContextType<typeof Context>;
|
||||
declare context: React.ContextType<typeof Context>;
|
||||
|
||||
render() {
|
||||
const { step = 'step1', code } = this.props.match.params;
|
||||
|
@@ -14,7 +14,7 @@ interface Props {
|
||||
|
||||
class ChangePasswordPage extends React.Component<Props> {
|
||||
static contextType = Context;
|
||||
/* TODO: use declare */ context: React.ContextType<typeof Context>;
|
||||
declare context: React.ContextType<typeof Context>;
|
||||
|
||||
form = new FormModel();
|
||||
|
||||
|
@@ -14,7 +14,7 @@ type Props = {
|
||||
|
||||
class ChangeUsernamePage extends React.Component<Props> {
|
||||
static contextType = Context;
|
||||
/* TODO: use declare */ context: React.ContextType<typeof Context>;
|
||||
declare context: React.ContextType<typeof Context>;
|
||||
|
||||
form = new FormModel();
|
||||
|
||||
|
@@ -16,7 +16,7 @@ interface Props
|
||||
|
||||
class MultiFactorAuthPage extends React.Component<Props> {
|
||||
static contextType = Context;
|
||||
/* TODO: use declare */ context: React.ContextType<typeof Context>;
|
||||
declare context: React.ContextType<typeof Context>;
|
||||
|
||||
render() {
|
||||
const {
|
||||
|
@@ -2,7 +2,8 @@
|
||||
/* eslint-env node */
|
||||
/* eslint-disable no-console */
|
||||
|
||||
import fs, { Stats } from 'fs';
|
||||
import type { Stats } from 'fs';
|
||||
import fs from 'fs';
|
||||
import webpack, { MultiCompiler } from 'webpack';
|
||||
import chalk from 'chalk';
|
||||
|
||||
|
Reference in New Issue
Block a user