Open bramvanhoutte opened 6 years ago
Does your bootstrap.js
still try to include jQuery and Bootstrap?
If so - you will need to remove them.
Remove bootstrap.js or JQuery and Bootstrap?
The error basically says that your bootstrap.js
file (nothing to do with twitter bootstrap) contains 2 bits of code, which webpack cannot find.
These 2 missing bits of code are bootstrap-sass
and jquery
IF you want to use jQuery - you'll need to install jquery to your project, with something like npm install jquery
If you don't want jQuery, then delete the line of code within bootstrap.js
which tries to include it, i imagine it will look something like $ = jQuery = requre('jquery')
--
As you're using UIKit and not Twitter Bootstrap, you will want to remove the code which tries to include it, this line of code probably just looks like require('bootstrap-sass')
So if you remove that bit of code from the bootstrap.js
then it wont error
Removing the bootstrap-sass
and jquery
referenced fixes the errors that occur when I run npm run dev
. I am however still stuck with UIKit components not displaying properly. I have linked app.css and app.js to the View but the still component isn't showing correctly.
I am wondering how the UIKit javascript is linked to the page. Since I can't find references to it anywhere.
Trying to get a simple dropdown to work.
<button type="button"></button>
<div uk-dropdown>This is the content</div>
This is the result:
This is the error i get when running
npm run dev
Components are all broken too