()
| 23 | routerScroll; |
| 24 | |
| 25 | @service |
| 26 | shoebox; |
| 27 | |
| 28 | constructor() { |
| 29 | super(...arguments); |
| 30 | if (!this.prerender.isPrerendering) { |
| 31 | this.router.on('routeDidChange', this.trackPage); |
| 32 | |
| 33 | /* Hax from https://github.com/DockYard/ember-router-scroll/issues/263 |
| 34 | to handle router scroll behavior when the page was initially served |
| 35 | pre-rendered |
| 36 | */ |
| 37 | this.routerScroll.set('preserveScrollPosition', true); |
| 38 | |
| 39 | setTimeout(() => { |
| 40 | if (!isDestroying(this) && !isDestroyed(this)) { |
| 41 | this.routerScroll.set('preserveScrollPosition', false); |
| 42 | } |
| 43 | }, 1000); |
| 44 | } |
| 45 |
nothing calls this directly
no outgoing calls
no test coverage detected