I am using Hugo
static site builder on my Windows 10
machine. I am trying to build a simple homepage using avicenna
theme. When I build the page locally using hugo server
, it renders the page correctly in the browser, just like what you would see if you head to avicenna
demo page https://themes.gohugo.io/theme/avicenna/ (I cannot post image of my own page because as a new user I am limited to posting a single image).
But after I use the hugo
command to build the final page and open the public
folder, I find an index.html
file which after I upload to my server, renders the page like below:
Here the problem is: (i) image is so enlarge and does not appear in the size that I see when I run hugo server
, and (ii) the page layout appears to be messed up, again unlike what I see when I run hugo server
.
I scoured online and found at some places (I am sorry, I don’t recall where) people had mentioned that one should change baseURL
from example.com
to one’s own domain name which I did. At some other places, people had mentioned using relativeURLs = true
and uglyURLs = true
in the config.toml
file. I did that too but in vain. Here’s what my config.toml
file looks like:
relativeURLs = true
uglyURLs = true
baseURL = "https://sharmavivek.com/"
languageCode = "en-us"
title = "Pierre Kahn"
theme = "avicenna"
googleAnalytics = "UA-1234-6"
timeout=3000
[params]
interests="Macroeconomics, Asset Pricing, Finance"
[[params.projects]]
I have avicenna
theme in themes
folder and I also tried uploading everything else that Hugo
was generating in the public
folder ( sitemap.xml
and folders categories
, css
, js
and tags
) but nothing worked. I have spent a lot of time trying to figure out what I am doing wrong but cannot figure out a way to fix it. Will appreciate any help.