Post CR updates which include:
- debouncing _refreshView function to avoid duplicate calls
- listening container refresh event (instead of window resize)
- code cleanup/generalization