Unlock seamless workflows and faster delivery with our latest releases – get the details

Structure: List items must be an array

The desk structure list takes an array of items. A common mistake is to passing a list of items as arguments instead of an array:

// Incorrect:
S.list()
  .title('Content')
  .items(
    S.listItem().title('Foo'),
    S.listItem().title('Bar')
  )

// Correct:
S.list()
  .title('Content')
.items([
S.listItem().title('Foo'), S.listItem().title('Bar')
])

Was this article helpful?