split-pane
seems to check the device width only on init and hides/shows the menu. Changes in device orientation (or window size) don’t seem to cause it to re-evaluate the width break point.
In the docs I didn’t see a way to externally trigger it to re-evaluate? Is the solution to write my own when
method that checks the width and listens for orientation changes?
I think that’s your best plan. This post looks to be the best out of the “how do I detect screen orientation changes?” discussion to me.
Thanks for the link. Last time I wrote my own when
method I was concerned by how often it was called on each page render depending on the work you need to do and how you do it it can get expensive.
A valid concern. I would try my best to make the actual when
method just return a boolean property, and have any harder work done in response to events and updating that property accordingly.