Closed JairusSW closed 5 months ago
If you take something like this:
import { JSON } from "."; @json class Base {} @json class Vec1 extends Base { x: f64 = 1.0; } @json class Vec2 extends Vec1 { @omit() y: f32 = 2.0; } @json class Vec3 extends Vec2 { z: f32 = 3.0; } const arr: Base[] = [ new Vec1(), new Vec2(), new Vec3() ]; console.log(JSON.stringify(arr));
It return this.
[{"x":1.0},{"x":1.0,"x":1.0,null},{null,"x":1.0,null,"x":1.0,"z":3.0}]
If you take something like this:
It return this.
[{"x":1.0},{"x":1.0,"x":1.0,null},{null,"x":1.0,null,"x":1.0,"z":3.0}]