I'm having an issue with the dropdown menu on my angular app. Every time I click on the Profile link to access the Account and Logout options, it automatically logs me out.
<nav class="navbar navbar-expand-lg bg-dark navbar-fixed-top">
<a class="navbar-brand text-white" href="#">Brand</a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNavDropdown" aria-controls="navbarNavDropdown" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNavDropdown">
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link text-white" routerLink="/dashboard">Dashboard</a>
</li>
<li class="nav-item">
<a class="nav-link text-white" routerLink="/dashboard">Documents</a>
</li>
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
Profile
</a>
<ul class="dropdown-menu" aria-labelledby="navbarDropdown">
<a class="dropdown-item" routerLink="/account">Account</a>
<a class="dropdown-item" routerLink="/account" (click)="authService.SignOut()">Log Out</a>
</ul>
</li>
</ul>
</div>
</nav>
UPDATE It seems like there could be a problem with how the .js or .css files are being included. Here is the content of my angular.json & style.css.
styles.css
@import '~bootstrap/dist/css/bootstrap.min.css';
@import "~bootstrap/dist/css/bootstrap.css";
@import "~font-awesome/css/font-awesome.css";
angular.json
"styles": [
"src/styles.css",
"node_modules/bootstrap/dist/css/bootstrap.min.css",
"node_modules/bootstrap/dist/css/bootstrap.css",
"node_modules/font-awesome/css/font-awesome.css",
"src/custom.css"
],
"scripts": [
"./node_modules/jquery/dist/jquery.js",
"./node_modules/jquery/dist/jquery.min.js",
"./node_modules/popper.js/dist/umd/popper.js",
"./node_modules/popper.js/dist/umd/popper.min.js",
"./node_modules/bootstrap/dist/js/bootstrap.min.js",
"./node_modules/bootstrap/dist/js/bootstrap.js"
]