I'm trying to use Bootstrap 4 in my theme for Magento 2. So i have created a requirejs-config.js (in my theme dir) with the next items :
var config = {
paths: {
"popper": "js/popper.min",
"jquery.bootstrap": "js/bootstrap.min"
},
shim: {
'jquery.bootstrap': {
'deps':['jquery' , 'popper']
}
}
};
And i want to use Bootstrap for my Carousel now like this :
<script type="text/javascript">
requirejs(['jquery' , 'popper' , 'jquery.bootstrap'], function ($ , Popper , jQueryBootstrap) {
$('#DesignitCarousel').carousel();
});
</script>
I do use popper 1.12.3 from the dist/umd directory and its loaded great. But i still get this error :
bootstrap.min.js:6 Uncaught Error: Bootstrap dropdown require Popper.js (https://popper.js.org) at bootstrap.min.js:6 at bootstrap.min.js:6 at bootstrap.min.js:6
Anyone any idea why my dependencies OR my requirejs in my phtml fille is not working ?