Skip to content

Editing files collection is very slow when you have a lot of entries #3952

@magomimmo

Description

@magomimmo

Describe the bug

Editing files collections is very slow, by making them almost unusable when you have a lot of entries.

To Reproduce

See attached zipped file.json sample containing 1000 items. Each item has just two fields:

  • name
  • id

Define a files collection as follow:

collections:
  - label: Files Collections
    name: files_collections
    files:
      - label: Items
        name: items
        file: data/file.json
        fields:
          - label: Items
            label_singular: Item
            name: items
            widget: list
            fields:
              - label: Name
                name: name
                widget: string
              - label: ID
                name: id
                widget: string

Listing is very slow (about 5 seconds). If you open the developer tool and reload the item list you'll see few violations. But the worst performance it happens when you add a new entry by using the Add item button:

  • it takes about 3/4 seconds before being able to scroll all the way down to the end of the list;
  • it takes about 6 seconds from the time you start writing in a field until you receive the feedback, making the editing of an entry unusable.

Expected behavior

The interaction with a file collection should be much more responsive, even with a lot of items

Applicable Versions:

  • Netlify CMS version: 2.12.15
  • Git provider: git-gateway/github
  • OS: ubuntu 18.04
  • Browser version: Google Chrome 83.0.4103.106

CMS configuration

See Above

file.zip

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions