# List page doesn't render theme properly

**URL:** https://discourse.gohugo.io/t/list-page-doesnt-render-theme-properly/24594
**Category:** support
**Created:** [April 9, 2020, 10:17pm UTC](https://discourse.gohugo.io/t/list-page-doesnt-render-theme-properly/24594 "2020-04-09T22:17:25Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Yuan-Meng](https://avatars.discourse-cdn.com/v4/letter/y/b19c9b/32.png) [@Yuan-Meng](https://discourse.gohugo.io/u/Yuan-Meng)
#### Post date: [April 9, 2020, 10:17pm UTC](https://discourse.gohugo.io/t/list-page-doesnt-render-theme-properly/24594/1 "2020-04-09T22:17:25Z")

</div>

I encountered a weird issue when trying to display subsection titles on a list page. Compared to single pages in this theme (which is hugo-coder), the text on the list page and its subpages (as shown in the picture below) is too small and too much to the left. Another issue is that content in `/content/projects/_index.md` didn’t render at all.

[![enter image description here](https://i.stack.imgur.com/fyMPt.png)](https://i.stack.imgur.com/fyMPt.png)

The only thing I did was to add a `list.html` file in `/layouts/projects`. Why would this happen and how can I render the theme properly on a list page? Thanks!! ([GitHub](https://github.com/Yuan-Meng/personal))

```auto
{{ define "title" }}
  {{ .Title }} · {{ .Site.Title }}
{{ end }}

{{ define "content" }}

  {{ if (eq $.Parent.Title "Projects") }}
    <ul class="no-bullet">
      {{ range .Paginator.Pages }}
      {{ .Render "li" }}
      {{ end }}
    </ul>
    {{ partial "pagination.html" . }}

  {{ else }}
    {{ range (where .Site.Pages "Section" "projects") }}
      <ul class="no-bullet">
        {{ range .Sections }}
        <li>
            <span class="date">{{ .Date.Format (.Site.Params.dateFormat | default "January 2, 2006" ) }}</span>
            <a class="title" href="{{ .Params.ExternalLink | default .RelPermalink }}">{{ .Title }}</a>
        </li>
        {{ end }}
      </ul>
     {{ end }}
   {{ end }}

{{ end }}

```

* * *

**Original post:**  
Under `/content/projects`, I have two separate categories, `cs` and `ds`. I wish to create a list page that displays the names of these two categories along with the URL to both. I know people asked similar questions before. However, none of the solutions I tried worked for me.

Below are my folder structure (relevant folders only) and the original code in `/layouts/_default/list.html` and `/layout/partial/list.html`. Which files should I modify and how in order to display subsections correctly? Thank you so much!!

In `/layouts/_default`:

```
{{ define "title" }} {{- if eq .Kind "taxonomy" -}}
  {{- i18n .Data.Singular | title -}}
    {{- print ": " -}}
  {{- end -}}

  {{- .Title }} · {{ .Site.Title -}}
{{ end }}
{{ define "content" }}
   {{ partial "list.html" . }}
{{ end }}

```

In `/layouts/partial`:

```auto
<section class="container list">
  <h1 class="title">
    {{- if eq .Kind "taxonomy" -}}
      {{- i18n .Data.Singular | title -}}
      {{- print ": " -}}
    {{- end -}}

    {{- .Title -}}
  </h1>
  {{ .Content }}
  <ul>
    {{ range .Paginator.Pages }}
    <li>
      <span class="date">{{ .Date.Format (.Site.Params.dateFormat | default "January 2, 2006" ) }}</span>
      <a class="title" href="{{ .Params.ExternalLink | default .RelPermalink }}">{{ .Title }}</a>
    </li>
    {{ end }}
  </ul>
  {{ partial "pagination.html" . }}
</section>

```

Folder structure of `content` and `layout`:

```auto
├── content
│ ├── about.md
│ ├── posts
│ │ └── amazon.md
│ └── projects
│ ├── _index.md
│ ├── cs
│ │ ├── _index.md
│ │ └── covid19.md
│ └── ds
│ ├── _index.md
│ └── covid19.md
├── layouts
│ ├── 404.html
│ ├── _default
│ │ ├── baseof.html
│ │ ├── list.html
│ │ └── single.html
│ ├── index.html
│ ├── partials
│ │ ├── 404.html
│ │ ├── analytics
│ │ │ └── fathom.html
│ │ ├── footer.html
│ │ ├── header.html
│ │ ├── home.html
│ │ ├── list.html
│ │ ├── page.html
│ │ ├── pagination.html
│ │ ├── posts
│ │ │ ├── commento.html
│ │ │ ├── disqus.html
│ │ │ ├── math.html
│ │ │ ├── series.html
│ │ │ └── utteranc.html
│ │ └── taxonomy
│ │ ├── categories.html
│ │ └── tags.html
│ ├── posts
│ │ ├── li.html
│ │ ├── list.html
│ │ └── single.html
│ └── projects
│ └── list.html
...

```

---

<div class="post-metadata">

### Author: ![maiki](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/maiki/32/16384_2.png) [@maiki](https://discourse.gohugo.io/u/maiki)
#### Post date: [April 9, 2020, 10:57pm UTC](https://discourse.gohugo.io/t/list-page-doesnt-render-theme-properly/24594/2 "2020-04-09T22:57:49Z")

</div>

Please share your project, per the advice at [Requesting Help](https://discourse.gohugo.io/t/requesting-help/9132).

---

<div class="post-metadata">

### Author: ![Yuan-Meng](https://avatars.discourse-cdn.com/v4/letter/y/b19c9b/32.png) [@Yuan-Meng](https://discourse.gohugo.io/u/Yuan-Meng)
#### Post date: [April 9, 2020, 11:00pm UTC](https://discourse.gohugo.io/t/list-page-doesnt-render-theme-properly/24594/3 "2020-04-09T23:00:58Z")

</div>

Ah sorry, just updated my question with my GitHub repo (also [here](https://github.com/Yuan-Meng/personal))!
