How to calculate with floating values in Hugo?

@jura, in your example, a floating value will be returned if 100 is replaced by 100.0 like

{{ div (mul $done 100.0) $total }}% done

doArithmetic internal function converts integer to float if one of arguments includes a float value.

2 Likes