Skip to content
This repository was archived by the owner on Apr 8, 2020. It is now read-only.
This repository was archived by the owner on Apr 8, 2020. It is now read-only.

Bootstrap not working in template #1117

Description

@DickvdBrink

After running yo aspnetcore-spa I chose angular and executing dotnet restore && dotnet run I try to open the url in the browser. Everything is looking good (style and stuff) but the bootstrap menu isn't working, if you make the page small you get the hamburger menu but it doesn't open on a click.
When you add the following code

 <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>

to the html it starts to work again, so i suspect something is wrong with the bundle and the bootstrap javascript isn't executed

Activity

  1. SteveSandersonMS commented on Jul 14, 2017

    @SteveSandersonMS
    Member

    The version of the templates on Yeoman was missing this line. If you add it to your boot-client.ts file, things should be working as expected.

    This is already fixed in the sources in this repo, hence closing as resolved.

  2. stibay commented on Aug 1, 2017

    @stibay

    This is still the issue in angular template from dotnet new so this issue should be open.
    import 'bootstrap'; needs to be added to boot-client-ts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions