How can i use Humanize


i am newbie and learn about Hugo, read book, test Thèmes…

I have this in my file <p>{{ .Site.Params.Author}}</p> and i want to add Humanize for get the first letter capitalize.

In my param file it’s writting `author: “Jean-Mi”

I try with Pipe before, after and look for a solution but… nothing

{{ .Site.Params.Author | humanize }} with or without point for context…

Nothing change, my name stay all in capital

Thank’s for help and explain



I don’t follow. In the site param, your name is not inn app capitals. What do you want to achieve?

In my params.yaml it’s writting

author: “Jean-Mi”

When am rendering the website, it’s writting : JEAN-MI and i don’t know why

So i want to use Humanize for get it like in my params

That’s not what I see here (config.toml)

  author = "Donald Duck"

and then <p>{{.Site.Params.Author}}</p> gives me “Donald Duck”. Do you see the uppercase version in your HTML, i.e. in your browsers web developer tools’ inspector, too? If not, I guess that your CSS is doing something fancy here.

Are you sure it is not just CSS?

1 Like


I solved it by using Css Style : style=“text-transform: capitalize;” and it’s ok.

If someone know how i can solve it by using Humanize it would be find for my knowledges and understanding.

If you have a string ‘Jean-Mi’ that you want to appear as such, simply do not use text-transform at all (I guess it was set to uppercase before). Feeding ‘Jean-Mi’ into text-transform: capitalize does nothing to this string, since every word of the string is already capitalized.

If i don’t use Style : style="text-transform: capitalize;
my text become : JEAN-MI :sweat_smile:

I have the same rendering with my categories in front matter :
categories : [“Blogging”, “Développement web”]

On my webpage

I try to find an issue with Humanize ?

<div class="column">
   {{ range $idx, $category := .Params.categories }}
   {{- if ne $idx 0 }}, {{ end }}
   <a href="{{ "categories/" | relURL }}{{ $category | urlize }}">{{ $category }}</a>
   {{- end }}

I’m sorry, but this is pointless. You only will get all upper case strings when something™ converts your text. The primary suspect would be a CSS file with text-decoration: uppercase, but it’s also possible that one of your templates converts the strings to upper case.

You’ve never posted the relevant information, so I’m giving up on it.

If you really want people to help you

  • provide them with the necessary information. Here, many like to see the Github repository of your site
  • answer their questions
  • follow there suggestions (or if you don’t, let them at least know why).

@chrillek Thank’s

I solved it with a css style and all is ok now…
I have no github repository yet
I follow this Tutorial
And only add Bulma css
But we can see on his website there’s the same case…