I've been integrating a bootstrap template into my Nuxt project but seem to be facing some challenges with loading the necessary scripts.
I've attempted to import the scripts into my nuxt.config.js
file in a couple of ways:
1.) Initially, I tried including the local source paths like this:
script: [
{ src: '~assets/js/jquery.js' },
{ src: '~assets/js/popper.min.js' },
{ src: '~assets/js/bootstrap.min.js' },
{ src: '~assets/js/jquery.cubeportfolio.min.js' },
{ src: '~assets/js/parallax.min.js' },
{ src: '~assets/js/jquery.appear.min.js' },
{ src: '~assets/js/jquery.themepunch.tools.min.js' },
{ src: '~assets/js/jquery.themepunch.revolution.min.js' },
{ src: '~assets/js/extensions/revolution.extension.actions.min.js' },
{ src: '~assets/js/extensions/revolution.extension.carousel.min.js' },
{ src: '~assets/js/extensions/revolution.extension.kenburn.min.js' },
{ src: '~assets/js/extensions/revolution.extension.layeranimation.min.js' },
{ src: '~assets/js/extensions/revolution.extension.migration.min.js' },
{ src: '~assets/js/extensions/revolution.extension.parallax.min.js' },
{ src: '~assets/js/extensions/revolution.extension.slideanims.min.js' },
{ src: '~assets/js/extensions/revolution.extension.video.min.js' },
{ src: '~assets/js/revolution-addons/before-after-affect/revolution.addon.beforeafter.min.js'}
],
2.) Another approach was to add the scripts as static files:
script: [
{ src: '/js/jquery.js' },
{ src: '/js/popper.min.js' },
{ src: '/js/bootstrap.min.js' },
{ src: '/js/jquery.cubeportfolio.min.js' },
{ src: '/js/parallax.min.js' },
{ src: '/js/jquery.appear.min.js' },
{ src: '/js/jquery.themepunch.tools.min.js' },
{ src: '/js/jquery.themepunch.revolution.min.js' },
{ src: '/js/extensions/revolution.extension.actions.min.js' },
{ src: '/js/extensions/revolution.extension.carousel.min.js' },
{ src: '/js/extensions/revolution.extension.kenburn.min.js' },
{ src: '/js/extensions/revolution.extension.layeranimation.min.js' },
{ src: '/js/extensions/revolution.extension.migration.min.js' },
{ src: '/js/extensions/revolution.extension.parallax.min.js' },
{ src: '/js/extensions/revolution.extension.slideanims.min.js' },
{ src: '/js/extensions/revolution.extension.video.min.js' },
{ src: '/js/revolution-addons/before-after-affect/revolution.addon.beforeafter.min.js'}
],
The content of my nuxt.config.js
file is provided below:
// Code snippet here
Upon inspecting the page, I noticed that the script files are not being loaded, causing issues with the proper rendering of the bootstrap theme.
You can see how it should look here:
The entire repository can be accessed here: https://github.com/SIeep/brandon-evans-portfolio
Any guidance or assistance on this matter would be greatly appreciated!
Thank you :)