node -v): 7.3.0 npm -v): 3.10.10Let me just say upfront, I feel like this is totally a webpack-noob question.
What I want to do is use Bootstrap v4 instead of v3. I can install the latest Alpha release of Bootstrap v4 using bower, and including its SASS codebase into a Laravel Mix-based stack was trivial.
The part I don't know how to do is include the JavaScript stack. The statement for loading Bootstrap from the NPM module is
require('bootstrap-sass');
So I've commented that out, but I don't know how to do is load bower_components/bootstrap/dist/bootstrap.js using a require() statement. I suppose I could load jQuery and Bootstrap independently of my compiled app.js file, but that seems inefficient.
Thanks in advance for your help.
Looks like there are instructions here: https://v4-alpha.getbootstrap.com/getting-started/download/#npm
I'd pull it all in through NPM, personally. So:
npm install [email protected] --save
resources/assets/js/app.jsrequire('bootstrap');
resources/assets/sass/app.scss@import '~bootstrap/dist/css/bootstrap.css';
See! I knew I was ignorant. Thank you for being so kind in pointing out that I hadn't read the fucking manual. :) In a year of freelancing I've gone from using dumb-packaging with Grunt, to Webpack, to Gulp, back to Webpack to Laravel Mix, so my head is swimming a bit with the choices.
Is there a way I can support the work you are doing?
Most helpful comment
See! I knew I was ignorant. Thank you for being so kind in pointing out that I hadn't read the fucking manual. :) In a year of freelancing I've gone from using dumb-packaging with Grunt, to Webpack, to Gulp, back to Webpack to Laravel Mix, so my head is swimming a bit with the choices.
Is there a way I can support the work you are doing?