4 ms·
Sure. But this is easier to understand, albeit means repeating code: class B { foo: number; bar?: number; baz: number; } I kno
by pavel_lishin 5y ago
Sure. But this is easier to understand, albeit means repeating code:
class B {
foo: number;
bar?: number;
baz: number;
}
I know these are toy examples, and I'm sure there are reasons why in the real world you'll be modeling things where this is not a good option. But I'd really need to be convinced that the CRUD webapps a lot of us write actually benefit from having this in our source code.