Development update – April 10, 2021

New website

The biggest thing I’ve done for the past weeks is creating a new website. I encourage you to read my last article, “Our new website, with dark mode!" to see what’s changed.

Website building performance

Using hugo --templateMetrics --templateMetricsHints, I managed to go from β‰ˆ14s build time to β‰ˆ10s.

4 seconds is not much, but the real thing is that now build time is quite linear, while it was polynomial before. What I mean by that is that every new page generated partials – page components. Most of those partials were the same on each page (e.g. the footer), or in each section of the website (e.g. the header).

By using Hugo’s cached partials, I was able to reuse partials if they were the same, instead of generating it again. This change saves a few seconds now, but will have a great impact when the website will grow.

Pages loading speed

Google PageSpeed Insights

PageBeforeAfter on mobile, 98/100 on desktop93/100 on mobile, 98/100 on desktop on mobile, 93/100 on desktop90/100 on mobile, 98/100 on desktop

See for metrics scores calculation.

Pain points (fixed or not)