I'm currently tackling a KineticJS project where I need to constantly create and delete shapes. However, I'm struggling with figuring out how to properly delete these shapes. I've been attempting to use the code snippet below:
$ myLayer.remove(myShape)
Despite numerous recommendations in various posts, the documentation indicates that this code will actually remove the layer from the stage rather than the shape from the layer. When I tested it in my project, it indeed removed the layer from the stage.
Am I missing something here or is there an alternative method to remove a shape from a layer?