Hugo, my new Home

Finally I moved from Wordpress to Hugo! An Open Source static site generator.

Not photo related, but still open sources. I don’t think there is anything wrong with Wordpress. It’s good and has many, many advantage. Just think the large number of plugins - and the resources!

With Hugo it can be quite simple, if you go with one of the plenty Hugo Themes. My aim was to copy my site as close as possible - and there was no similar theme.

So I started Hugo completely without theme and copied my structure as good as I could. Some functions where a little challenge, like the image compare slider (many plugin in Wordpress for that). In Hugo you need to write a shortcode for that, some JavaScript with it and make that run.

Hugo, other than the MySQL based Wordpress CMS, has no database, the site is totally static. This brings a few advantage, but they are major advantage:

  • No database means that pages do not have to be created by the server. You do not need to have high end servers to make your pages load fast.
  • No database also means that your website has no function. Like functions where a hacker can get in, create a mail relays and SPAM till you notice it (or till your host disables your website). Generally a static site is much safer.
  • Pages are much leaner. You can really control what goes into the page. I don’t mean what you see, I mean what you don’t see, like what’s inside the < head > of your page. Wordpress sometimes writes 10+ css links, or 100s of css classes that you don’t really need.

On the way I learned also Tailwind, makes css writing fun (it wasn’t before for me).

I am still learning more and more about Hugo and they more you know the more fun it is to code it.

If you have a photo website, with many images, gallery view etc, consider Hugo, it makes your image heave pages load much faster. And you have easily have features like LazyLoad and automatic *.webp alternatives.

Make the Sky Black!
Make the Sky Black!
© 2019 Dark RAW