Kirby table is slow…

I’ve been using Pagetable | Kirby CMS Plugins with a lot of v2 and v3 projects with ease. The new table layout is super nice but it’s lacking for example the option to click on a column to sort it. But the biggest issue yet with Kirby 5.0.3 for me, it is struggling to show results of 30 items. The snappy feeling of kirby is not there anymore.

Is there some features I’ve missed that would speed up a bit the process or is it a bug?

Here’s a video

and here’s the code:

  works_all:
    label: All (table)
    icon: draft
    columns:
      - width: 1/1
        sections:
          drafts:
            label: Works All
            type: pages
            batch: true
            status: all
            templates: work
            limit: 30
            layout: table
            columns:
              info: false
              client: true
              date:
                type: text
                value: '{{ page.date.toDate("Y") }}'
                width: 3/24
              # designers:
              #   type: tags
              #   width: 1/12
              # work_field: 
              #   label: Domaines
              #   type: tags
              # categories:
              #   label: Categories
              #   value: '{{ page.category_print }} {{ page.category_identity }} {{ page.category_digital }} {{ page.category_signage }} {{ page.category_image }}'
              #   type: tags
              homepage_visible:
                label: Home
                width: 2/16
              homepage_link:
                label: Link
                width: 2/16
              case_study_ready:
                label: Case study
                width: 2/16

Try adding this to your drafts section blueprint

rawvalues: true

and see if it helps. Although I think that will not render your toggles (you will see values TRUE/FALSE instead).

To see if it is just the table layout that causes the problem you can try changing the layout to list (or cards etc).

Hi, many thanks for the reply. I’ve tried it. The table is super fast but all the toggles are “ON” despite the fact that they are not. ;/ True / False would be more helpful though.

I’ve already created a layout with cards and it is almost instant. The table with rendered toggle seems to struggle. I’m wondering if it’s possible to improve that Kirby side?

I didn’t upgrade to 5 yet. In 4.7 at least I see true/false when using rawvalues. So something seems to have changed in 5 in this regard.

The table performance thing is a known issue (I was hoping it had been fixed in Kirby 5).

Just a thought… If you define the toggle column as type:text in your table setup, does that show correct true/false values?

# ...
  layout: table
  rawvalues: true 
    columns:
      case_study_ready:
        type: text
        # Optionally customize the text?
        # value: "{{ page.case_study_ready.isTrue ? 'Yepp' : 'Nope' }}"
        # ...

Yes, it works. many thanks for the tip. Well, at least, I know the table layout needs some fixes. I’ve moved directly from 3.x to 5.x.