How to import popper.js?

Qrzysio picture Qrzysio · Aug 12, 2017 · Viewed 127.6k times · Source

It seems to be a lame question, but I cannot to figure it out. How to import popper.js which comes toghether with Bootstrap 4 beta?

I use bower and I've installed Bootstrap 4 beta. Now in bower_components folder there is popper.js directory, which contains a few sub-folders. The problem is there is no dist folder and popper.min.js file.

Bootstrap 4 guide links to CDN: https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js

But how to import popper.js without CDN? Where to find popper.min.js file?

EDIT: Even if I download zip from popper.js website it contains exactly the same files as from bower.

Answer

Sora picture Sora · Aug 13, 2017

I ran into the same problem.

I downloaded the 'popper.min.js' file from the CDN on the bootstrap website.

See here: https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js

Easier than compiling the project.

Important: You must include popper after jquery but BEFORE bootstrap.