1

I use Bootstrap studio 5 and I published the website directly from it. When I navigate to it (https://my-website-name.bss.design/) I notice that javascript functionalities are not there. There is an error in the console:

script.min.js?h=fb924772e895278c3c5f2d161d9d0ebd:1 Uncaught TypeError: Cannot read properties of undefined (reading 'addEventListener') at script.min.js?h=fb924772e895278c3c5f2d161d9d0ebd:1:649

It's at the first line but the file only has one line (minified) so this is where the problem is: document.addEventListener("DOMContentLoaded",(function(){[].slice.call(document.querySelectorAll ...

Somehow document is undefined which makes no sense since that file is loaded at the end of the html body just like it should. Can somehow please tell me what the heck is going on here? I can provide the full script.min.js if necessary.

I didn't try anything since the problem itself makes no sense to me and Bootstrap studio automatically minifies javascript without giving me options.

Flampt
  • 23
  • 3
  • The error message says that the error occurs on column 649, not on column 1, so the code snippet you provided isn't where the error is. What does the code on column 649 do? (maybe there is a function that's overriding the global `document` variable, but without more information it's impossible to tell) – Live bug help - www.dialect.so Jan 05 '23 at 21:29

0 Answers0