Prevent destroying component on route change

I have a component that is very expensive to render. It’s a map, and I draw thousands of data points on it, which can take a few seconds. When I leave the page (move to a new route) and then come back, I don’t want to have to re-render. The data is all maintained in a service, so that’s not the problem - it’s the actual rendering.

This question has been asked in the past, but seems to never have been answered properly. There was apparently a somewhat hacky solution involving ContainerView, which has since been deprecated. I’m on Ember 2.3 now. Is there any way to accomplish what I’m trying to do? If not, is there any plan to implement something like this in the near future?

Here’s the link to the old thread:

1 Like