Closed
Description
Opening new bug since the previous got closed without any explanation.
Why strictPropertyInitialization should require strictNullChecks?
class C {
foo: number;
bar = "hello";
baz: boolean;
// ~~~
// Error! Property 'baz' has no initializer and is not assigned directly in the constructor.
constructor() {
this.foo = 42;
}
}
Without stringNullChecks, I can solve the error explicitly assigning undefined to baz.