Dropdown menu does not appear - Project Laravel

0

I made a layout in which I want to put a navbar where I want to put a dropdown, however the dropdown menu does not appear, just the button there ... I already tried to put Jquery but it did not work,

<!DOCTYPE html>

            @yield ('titulo', 'PetShop do Amigão')      

<link rel="stylesheet" href="js/app.js">
<link rel="stylesheet" href="css/app.css">

  

<nav class="navbar navbar-expand-lg navbar-dark bg-dark">
  <a class="navbar-brand" href="/PetShop/public">PetShop do Amigão</a>
  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
    <span class="navbar-toggler-icon"></span>
  </button>

  <div class="collapse navbar-collapse" id="navbarSupportedContent">

    <ul class="navbar-nav mr-auto">
      <li class="nav-item active">
        <a class="nav-link" href="/PetShop/public">Home <span class="sr-only">(current)</span></a>
      </li>
      <li class="nav-item">
        <a class="nav-link" href="#">Rações</a>
      </li>
      <li class="nav-item">
        <a class="nav-link" href="#">Coleiras</a>
      </li>
      <li class="nav-item">
        <a class="nav-link" href="#">Remédios</a>
      </li>
    </ul>

    <ul class="navbar-nav navbar-right">
      <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">
           Olá, Usuário
         </a>
         <div class="dropdown-menu" aria-labelledby="navbarDropdown">
           <a class="dropdown-item" href="#">Minha Conta</a>
           <a class="dropdown-item" href="#">Meu Carrinho</a>
           <a class="dropdown-item" href="#">Sair</a>
         </div>
     </li>
  </ul>

</div>

@yield ('content')

    
asked by anonymous 25.11.2018 / 19:41

1 answer

0

Show YES IT'S RIGHT

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title>@yield('titulo', 'PetShop do Amigão')</title>
    <style media="screen"> </style>

    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">

  </head>

  <body>

    <nav class="navbar navbar-expand-lg navbar-dark bg-dark">
      <a class="navbar-brand" href="/PetShop/public">PetShop do Amigão</a>
      <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
        <span class="navbar-toggler-icon"></span>
      </button>

      <div class="collapse navbar-collapse" id="navbarSupportedContent">

        <ul class="navbar-nav mr-auto">
          <li class="nav-item active">
            <a class="nav-link" href="/PetShop/public">Home <span class="sr-only">(current)</span></a>
          </li>
          <li class="nav-item">
            <a class="nav-link" href="#">Rações</a>
          </li>
          <li class="nav-item">
            <a class="nav-link" href="#">Coleiras</a>
          </li>
          <li class="nav-item">
            <a class="nav-link" href="#">Remédios</a>
          </li>
        </ul>

        <ul class="navbar-nav navbar-right">
          <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">
               Olá, Usuário
             </a>
             <div class="dropdown-menu" aria-labelledby="navbarDropdown">
               <a class="dropdown-item" href="#">Minha Conta</a>
               <a class="dropdown-item" href="#">Meu Carrinho</a>
               <a class="dropdown-item" href="#">Sair</a>
             </div>
         </li>
      </ul>

    </div>
</nav>
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js"integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js"integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
  @yield('conteudo')
</body>




</html>
    
25.11.2018 / 20:40