0

I created na ASP.NET MVC project, and the bootstrap version 3.3.7 was included. This is in Visual Studio 2019.

However, I need to include bootstrap 4.0.0. I tried through NuGet, but it said it is incompatible. So, how can I install bootstrap 4.0.0?

3
  • 1
    Show exactly what message you get. As bootstrap is client side, you can add any javascript library to asp.net mvc app, if not with nuget, then manually. Commented Jan 2, 2020 at 12:59
  • Have a look at installing it using NPM Commented Jan 2, 2020 at 12:59
  • This could also be of use: c-sharpcorner.com/blogs/asp-net-mvc-5-install-bootstrap Commented Jan 2, 2020 at 13:05

2 Answers 2

1

You can right-click your solution and click 'Add', then 'Client-Side Library' to bring up the Client-Side library manager. In here if you search for 'twitter-bootstrap' (from CDNJS) you should find the 4.0 library.

Using a client-side library manager like this should make the process a bit more manageable than simply downloading bootstrap from their website (although that is also an option).

Good luck.

Sign up to request clarification or add additional context in comments.

Comments

0

If you are getting error from nuget the you can just add the CSS and Script. MaxCDN provides CDN support for Bootstrap's CSS and JavaScript. You must also include jQuery:

MaxCDN:
<!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css">

<!-- jQuery library -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>

<!-- Popper JS -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.16.0/umd/popper.min.js"></script>

<!-- Latest compiled JavaScript -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.4.1/js/bootstrap.min.js"></script>

For more info you can this link

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.