我有这样的结构:
export class Foo {
private variable = 'value';
static Bar = class {
constructor() {
}
};
constructor() {
}
}
正在运行ng lint
会给我:Declaration of public static member variable not allowed to appear after declaration of private instance member variable
确定。交换订单后:
export class Foo {
static Bar = class {
constructor() {
}
};
private variable = 'value';
constructor() {
}
}
我知道得到:Declaration of private instance member variable not allowed to appear after declaration of public instance member function
我应该如何修复此Lint错误?