calintat / minimal

Personal blog theme powered by Hugo
https://themes.gohugo.io/minimal/
MIT License
404 stars 222 forks source link

partial formatting upon deployment #45

Closed nhejazi closed 6 years ago

nhejazi commented 6 years ago

I just recently came across this theme and have been converting my blog over from another hugo theme. After forking the theme (to add MathJax support), I added it as a submodule and noticed that deployment via netlify seems to cause an odd formatting issue -- it seems that the theme partially renders but all content appears shifted to the upper left, with line formatting/wrapping being ignored.

The build looks fine when rendered locally via hugo server:

screen shot 2017-12-27 at 9 46 27 pm

...but it doesn't look quite right upon deployment:

screen shot 2017-12-27 at 9 46 41 pm

I looked at a few possibly related issues and thought this might be due to a new hugo version but setting the env var HUGO_VERSION to 0.31.1 (the latest on my system) didn't seem to resolve the issue. Any help would be much appreciated.

nhejazi commented 6 years ago

RESOLVED. It might be worth labeling this under "question" in case anyone else runs into this error in the future.

As best as I can tell, there exists theme-specific variation around how the core parameter baseURL may be specified in config.toml. For example, with my previous blog theme (future-imperfect), it is valid/sufficient to specify baseURL = "/", which held -- I guess because of its generic nature -- even when site is deployed via netlify. That is not the case with minimal. To get the site to render properly upon deployment, baseURL needed to be specified explicitly -- in my case this was baseURL = "https://myrepo.netlify.com/".