assets not getting loaded
Raghwendra-Dey opened this issue · comments
When i run the site locally it only showed the plain html, it can't import the css and some other files. It seems that it imports all the /assets/*
from the root url
instead of relative_url
, since i have my site not on the root of the domain but in some other repo but it can't load the /assets/*
files, even when i set the baseurl variable in _config.yml
file. I searched for the /assets/css/main.css
in the repo and could find many places where href is directly given as /assets/css/main.css
instead of with | relative_url
The screenshot of the output of the running the server is attached herewith for you to look into:
Sure, the baseurl is not getting attached. Will check this. You can try replacing the head links {{site.url}}{{site.baseurl}}/assets/ and configure the base url in _config.yml
I cloned your repo only and just put the baseurl
argument in the _config.yml
file, rest everthing is same as your repo.
Sure, here's my _config.yml
file screenshot:
Lines 6
and 7
are the only lines which i changed, everything else is exactly same.
When i served this locally it showed me this:
Then i tried searching for the missing /assets/img/post..
in the repo i found it only in here(line 13):
I replaced it with appending {{site.baseurl}}
but it only corrected one thing, i.e. output after that is: