We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
window
1 parent 648d592 commit 0de72c5Copy full SHA for 0de72c5
app/initializers/hashchange.js
@@ -27,8 +27,9 @@ function hashchange() {
27
}
28
29
export function initialize() {
30
- if (typeof window.addEventListener === 'undefined') {
31
- return; // Fastboot
+ if (typeof window === 'undefined' || typeof window.addEventListener === 'undefined') {
+ // Don't run this initializer under FastBoot
32
+ return;
33
34
window.addEventListener('hashchange', hashchange);
35
0 commit comments