DEV Community

Discussion on: Managing ASP.NET Core MVC front-end dependencies with npm and webpack (part 2)

Collapse
 
fawkes07 profile image
Hugo Ruvalcaba

Hey bro!

Great post! this guide was awesomely helpfully as first aproach of webpack! just one question. I followed this project as learn process but I stoped with a little prolem, My dropdown buttons doesn't work :(

Searching in other sources I see that popper is requeried for this but in your code is already imported! (@popperjs/core). So what is the real problem here? Any idea? I just want to be sure I know why this could happend to avoid and learn how to fixit by my own for future projects.

Again. Thanks a lot for your time writing this!

Collapse
 
larswillemsens profile image
Lars Willemsens

Hi!
First thing to check: on that page where you're using the dropdown, you should include the 'bootstrap_js.entry.js' script.
If you have the log statement in there, you should see 'The 'bootstrap_js' bundle has been loaded!' in the console.
Then, ensure that the popper import is listed in 'bootstrap_js.js'. To be absolutely sure, you can even inspect 'bootstrap_js.entry.js'. It's unreadable, but searching for popper should give you some results.
Hope this helps!