Skip to content Skip to sidebar Skip to footer

Heroku Bootstrap Navbar Not Rendering

So... I have a rails app where I am using a bootstrap navbar. It all works locally on my machine but after pushing to Heroku it renders everything accept the navbar. Take a look at

Solution 1:

Please try this to solve the problem (add the <link> elements to your <head>):

<head>

<!-- Bootstrap first -->
<link rel="stylesheet" media="all" href="/assets/base/bootstrap.css"  type="text/css">

<!-- Your extra styling -->
<link rel="stylesheet" media="all" href="/assets/application-52c2922bf3888faae91327ac966f10f93474a159ef20a14180eb9bd164ed87cf.css" data-turbolinks-track="true" />

</head>

Your linking to bootstrap.css didn't work, because <link <href='/assets/base/bootstrap.css' is no valid code, see the < before href.


Solution 2:

Try this

https://www.bootstrapcdn.com

I just include that links and this work fine for me. For me that was good solution. Also I did - 1) rake assets:precompile; 2) config.assets.compile = true


Post a Comment for "Heroku Bootstrap Navbar Not Rendering"