about summary refs log tree commit diff
path: root/app/javascript
diff options
context:
space:
mode:
Diffstat (limited to 'app/javascript')
-rw-r--r--app/javascript/packs/public.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/app/javascript/packs/public.js b/app/javascript/packs/public.js
index dc18da853..c83e2889a 100644
--- a/app/javascript/packs/public.js
+++ b/app/javascript/packs/public.js
@@ -79,7 +79,10 @@ function main() {
         .catch(error => console.error(error));
     }
 
-    new Rellax('.parallax', { speed: -1 });
+    const parallaxComponents = document.querySelectorAll('.parallax');
+    if (parallaxComponents.length > 0 ) {
+      new Rellax('.parallax', { speed: -1 });
+    }
 
     const history = createHistory();
     const detailedStatuses = document.querySelectorAll('.public-layout .detailed-status');