i downloaded this template here https://bootstrapmade.com/regna-bootstrap-onepage-template/
my goal is to get it going in rails 7. i copied the content of index.html to experiment.erb.html.
And i copied the javascript content to app javascript.
my importmap.rb looks like this
pin "application", preload: true
pin "@hotwired/turbo-rails", to: "turbo.min.js", preload: true
pin "@hotwired/stimulus", to: "stimulus.min.js", preload: true
pin "@hotwired/stimulus-loading", to: "stimulus-loading.js", preload: true
pin_all_from "app/javascript/controllers", under: "controllers"
pin "bootstrap", to: "https://ga.jspm.io/npm:bootstrap@5.1.3/dist/js/bootstrap.esm.js"
pin "@popperjs/core", to: "https://unpkg.com/@popperjs/core@2.11.2/dist/esm/index.js" # use unpkg.com as ga.jspm.io contains a broken popper package
pin_all_from "app/javascript/aos", under: "aos"
pin_all_from "app/javascript/purecounter", under: "purecounter"
pin_all_from "app/javascript/glightbox", under: "glightbox"
pin_all_from "app/javascript/isotope", under: "isotope"
pin_all_from "app/javascript/swiper", under: "swiper"
pin_all_from "app/javascript/main", under: "main"
my application.js looks like this:
// Configure your import map in config/importmap.rb. Read more: https://github.com/rails/importmap-rails
import '@hotwired/turbo-rails';
import 'controllers';
import 'bootstrap';
import 'aos/aos';
import 'purecounter/purecounter_vanilla';
import 'glightbox/glightbox';
import 'isotope/isotope';
import 'swiper/swiper-bundle.min';
import 'main/main';
My error message in chrome browser is
aos-75b913982a069d95d17deb4a5fa63c1019abfca2c7bad6623a03e046e1e8dd31.js:1 Uncaught TypeError: Cannot set properties of undefined (setting 'AOS')
at aos-75b913982a069d95d17deb4a5fa63c1019abfca2c7bad6623a03e046e1e8dd31.js:1:182
at aos-75b913982a069d95d17deb4a5fa63c1019abfca2c7bad6623a03e046e1e8dd31.js:1:187
(anonymous) @ aos-75b913982a069d95d17deb4a5fa63c1019abfca2c7bad6623a03e046e1e8dd31.js:1
(anonymous) @ aos-75b913982a069d95d17deb4a5fa63c1019abfca2c7bad6623a03e046e1e8dd31.js:1
[filestructure in vscode1
if you know what i have to fix, please explain.