Issue with loading third party library in Angular 6
Issue with loading third party library which is dependence on another third party library. In my case, i'm using bootstrap(v3.3.7) which is required JQuery. I included these libraries as per angular suggested way and successfully compile the application, if run it in browser i got a console error.
Versions
"dependencies": {
"@angular/animations": "^6.0.0",
"@angular/common": "^6.0.0",
"@angular/compiler": "^6.0.0",
"@angular/core": "^6.0.0",
"@angular/forms": "^6.0.0",
"@angular/http": "^6.0.0",
"@angular/platform-browser": "^6.0.0",
"@angular/platform-browser-dynamic": "^6.0.0",
"@angular/router": "^6.0.0",
"@types/bootstrap": "^3.3.33",
"@types/jquery": "^3.3.1",
"bootstrap": "^3.3.7",
"core-js": "^2.5.4",
"jquery": "3.3.1",
"malihu-custom-scrollbar-plugin": "3.1.5",
"rxjs": "^6.0.0",
"zone.js": "^0.8.26"
}
Sample code
angular.json

app.component.ts

Console Error

did u add bootstrap js? also u can use CDN for them
@WandererInVoids yes, i have installed bootstrap via npm and include it in angular.json file. I'm facing this issue not only for bootstrap also occur materialize-css . Is angular changed the way of loading/including third party library files to application?
Any updates on this issue??
You are setting jQuery as a global, however you are importing using a direct import. This will result in having jQuery twice in your application.
See https://github.com/angular/angular-cli/wiki/stories-global-scripts#using-global-libraries-inside-your-app and https://github.com/angular/angular-cli/wiki/stories-third-party-lib
This issue and determined that it doesn't fall into the bug report or feature request category. This issue tracker is not suitable for support requests, please repost your issue on StackOverflow using tag angular-cli.
If you are wondering why we don't resolve support issues via the issue tracker, please check out this explanation.
This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.