Creating a custom class extending Container in PIXI.js:
export class CustomContainer extends Container {
constructor(width: number, height: number) {
super();
var sprite: Sprite = Sprite.fromImage("assets/images/elephant.png");
super.addChild(sprite);
}
}
However, when attempting to access a Container property from a new instance of the class, an error is thrown: [ts] Property 'x' does not exist on type 'CustomContainer'
var container1: CustomContainer = new CustomContainer(100, 300);
container1.x = 200;