Unable to resolve "styles.main.css"
When using the baseURL of "/" (as recommended in a number of places, including here), the main.css file is attempting to be loaded from http://styles/main.css, which obviously doesn't resolve anywhere.
Here's the relevant line of code: https://github.com/tomanistor/osprey/blob/master/layouts/partials/header.html#L74
I fixed this by changing it to the following:
<link rel="stylesheet" href="{{ .Site.BaseURL }}styles/{{ if .Site.Params.cacheBustCSS }}{{ index .Site.Data.styles.hash "main.css" }}{{ else }}main.css{{ end }}" type="text/css">
I simply removed the leading / before styles/, so it would load from [baseUrl]/styles/main.css.
Cheers, Aaron (insp3ctre)
Just FYI the same issue happened on the blog.html page. I changed the same element of the line as follows:
<div class="col-xs-12"><h3><a href="{{ .Site.BaseURL }}blog/">View All</a></h3></div>
Cheers, Aaron (insp3ctre)
This can also be solved with:
{{ if .Site.Params.cacheBustCSS }}
<link rel="stylesheet" href="{{ (index .Site.Data.cachedAssets "main.css") | absURL }}">
{{ else }}
<link rel="stylesheet" href="{{ "/styles/main.css" | absURL }}">
{{ end }}
Similar issue with the og:image which could be:
<meta property="og:image" content="{{ .Site.Params.opengraphImage | absURL }}">
And with the favicon, which could be:
<link rel="icon" type="image/png" sizes="16x16" href="{{ "/images/logo/favicon.ico" | absURL }}">
However setting the baseURL to / actually uncovers additional problems. For example, og:url is equal to .Site.BaseURL which it seems should be a full url with domain/protocol, but in this case would be just a /.