popper.js

Bootstrap 4 popper is undefined

99封情书 提交于 2019-12-02 03:52:36
I'm trying to get a dropdown going and whenever I click on the button I get TypeError: popper is undefined . I tried importing the bundle instead of bootstrap // import "bootstrap"; import 'bootstrap/dist/js/bootstrap.bundle.js'; I tried importing jquery first import "jquery"; import "bootstrap"; I tried importing popper as well import "popper.js/dist/umd/popper.min.js"; import "jquery"; import "bootstrap"; I also tried including popper from a CDN before any other scripts <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.12.9/umd/popper.min.js"></script> And I tried just about

Uncaught SyntaxError: Unexpected token export - popper.js error

邮差的信 提交于 2019-12-02 03:29:42
Angular is giving the error: popper.js in bootstrap 4 gives SyntaxError Unexpected token export I'm getting this error from browser console. Even I changed the popper.min.js location reference but no use.. node_modules/popper.js/dist/umd/popper.min.js node_modules/popper.js/dist/ems/popper.min.js Angular.json "scripts": [ "node_modules/bootstrap/dist/js/bootstrap.min.js", "node_modules/jquery/dist/jquery.slim.min.js", "node_modules/popper.js/dist/popper.min.js" ] Bootstrap.min.js is depend on the popper.min.js , change the order as follows, "scripts": [ "node_modules/jquery/dist/jquery.slim

Bootstrap 4 Navbar doesnt collapse in Angular4

断了今生、忘了曾经 提交于 2019-12-01 13:00:01
I'm working with Bootstrap 4 and Ng-Bootstrap in an Angular 4 Project, i have linked the que bootstrap.css in my angular-cli.json this way "styles": [ "../node_modules/bootstrap/dist/css/bootstrap.css", "styles.css" ], and imported the NgbModule in my app.module that looks like this import { BrowserModule } from '@angular/platform-browser'; import { NgModule } from '@angular/core'; import { NgbModule } from '@ng-bootstrap/ng-bootstrap'; import { AppComponent } from './app.component'; @NgModule({ declarations: [ AppComponent ], imports: [ BrowserModule, NgbModule.forRoot() ], providers: [],

How to import popper.js?

孤街浪徒 提交于 2019-11-30 07:57:08
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

How to import popper.js?

你说的曾经没有我的故事 提交于 2019-11-29 10:41:09
问题 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

Bootstrap 4 Dropdown - Disable auto placement caused by popper.js

最后都变了- 提交于 2019-11-28 12:41:17
I'm working with Bootstrap 4 dropdown and there are about 18 dropdown items. Because the height is too much, popper.js automatically moves the dropdown away from its original position to the top of the screen. How do I prevent this? I always want the dropdown to appear right below the button that toggles it. Thanks Posting code as requested - ( I'm using C# but the code should convey the point I'm hoping) <div class="dropdown"> <span class="p-2 text-uppercase font-weight-semi-bold pointer dropdown-toggle" href="#" role="button" id="dropdownMenuLink" data-toggle="dropdown" aria-haspopup="true"

Issue Loading PopperJS and Bootstrap via RequireJS, Even After Using Recommended PopperJS Version

倾然丶 夕夏残阳落幕 提交于 2019-11-28 08:06:57
问题 I'm attempting to load jquery, popperjs, and bootstrap (v4-beta) via requirejs and in the console I keep getting: Uncaught Error: Bootstrap dropdown require Popper.js (https://popper.js.org) at bootstrap.js:6 at bootstrap.js:6 at bootstrap.js:6 Here's my code in main: requirejs.config({ paths: { 'jquery': 'lib/jquery', 'popper': 'lib/popper', 'bootstrap': 'lib/bootstrap' }, shim: { 'bootstrap': ['jquery', 'popper'] } }); requirejs(['jquery', 'popper', 'bootstrap'], function(jquery, popper,

popper.js in bootstrap 4 gives SyntaxError Unexpected token export

*爱你&永不变心* 提交于 2019-11-28 07:08:04
I tried install bootstrap 4, and included following links <script src="libs/jquery/dist/jquery.min.js"></script> <script src="libs/tether/dist/js/tether.min.js" ></script> <script src="libs/popper.js/dist/popper.js"></script> <script src="libs/bootstrap/dist/js/bootstrap.min.js" ></script> But The following error occurs : Uncaught syntaxError: Unexpected token export Any ideas how to fix it? I encountered the same issue if I use popper.js from CDN network like cdnjs . If you observe the source code of Bootstrap 4 examples like for example Navbar you can see that popper.min.js is loaded from:

How to use Popper.js with Bootstrap 4 beta

不羁岁月 提交于 2019-11-27 18:40:16
I'm old school, so I downloaded the source code to 1.12.0 and then did the following: <script src="/popper.js-1.12.0/dist/popper.js"></script> <script src="/bootstrap-4.0.0-beta/dist/js/bootstrap.js"></script> But I'm getting: Uncaught SyntaxError: Unexpected token export on line 2294 where it says: export default Popper; You want to use the dist target specified in the package.json file as main entry . In this case, you are looking for the umd build ( dist/umd/popper.js ) What's UMD? The UMD pattern typically attempts to offer compatibility with the most popular script loaders of the day (e.g

Styling a tooltip (popper.js / bootstrap v4 beta)

本秂侑毒 提交于 2019-11-27 08:58:42
I've installed bootstrap v4 beta and with it the popper.js (tooltip.js) library. I'm trying to use it's tooltip function. So I managed to make it appear but I can't change it's appearance/style for the life of me. I've looked over their documentation several times but I can't figure it out. (I just hate a so called "documentation" that doesn't have examples). So here is my html: <span data-toggle="tooltip" data-placement="right" title="Tooltip on right">Simple Task Management</span> I activated it on data-toggle in js: $(function() { $('[data-toggle="tooltip"]').tooltip() }) I noticed that