Is it possible not including author image in profile homepage #44
-
Hi, I want to minimalize my homepage, but I love the presentation of profile layout. I was wondering if there is a config to remove the author image in profile homepage, but keep that in blog footer. Thank you! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
There isn't a config parameter specifically for this as you can obviously not provide the author image and this will remove it (but will also remove it from the article footer too). A quick workaround for this would be to provide your own custom profile homepage. You can simply copy <!-- Remove these 3 lines -->
{{ with .Site.Author.image }}
<img class="mb-2 rounded-full w-36 h-36" src="{{ . | relURL }}" />
{{ end }} Providing a template in this way means your homepage won't break with any theme updates in the future. The exampleSite uses this exact process if you'd like to see a working example and the theme Homepage Layout docs also describe the process in more detail. |
Beta Was this translation helpful? Give feedback.
There isn't a config parameter specifically for this as you can obviously not provide the author image and this will remove it (but will also remove it from the article footer too). A quick workaround for this would be to provide your own custom profile homepage. You can simply copy
congo/layouts/partials/home/profile.html
to your project and name it/layouts/partials/home/custom.html
then just remove the block in the template that inserts the image (see below). If you then change the theme config to usecustom
as thehomepage.layout
value it will use your custom template.