Relations in main layout beta is out

Hello, dear community members!

As you may know, we’re working on improving the relations feature.
In particular, we are reworking the display and searching through relations. We are moving relations to the main layout of the edit view to reduce the load time and improve UX.

The beta version of the feature is live and we would love to hear what you think!

The feature is available in the Strapi v4.5 beta, to test it please run the following command:

npx create-strapi-app@beta my-project
or
npx create-strapi-app@4.5.0-beta.0 strapi-relations-beta

Check out the beta user guide docs for this feature.

Please do share your feedback in the thread below to help us improve it, alternatively there will be a #relations-beta channel on Discord as well.

Thanks!

9 Likes

Hi, and thanx! Quick question: will we be able to change the order of items?

1 Like

Not initially but this is something the team wants to work on. This was simply the first step towards the improvements we wanted to make.

2 Likes

This is far better than the previous layout!

This is great! Can’t wait for this to be released. So much simplification with the user handover.
Indeed, reordering the items would be a must.

Is it possible to create new item? Somethink like tags?

Ordering (sorting) the relation can be viewed as a parametrized n:m database table. Meaning one (or more) columns would have to be added to the table. So far, Strapi doesn’t support that - although it has been on the roadmap for quite some time. What I personally do is that I have a String attribute called sortRelationName which gets updated accordingly with POST/PATCH/PUT request from the frontend.

Awesome, that’s a great improve

Does this mean we can set relations as required fields now?

Thank you everyone :slight_smile:

will we be able to change the order of items?

  • Now the order is consistent (before it was kind of random) & everything you add will be added to the end of the list. So as a workaround, if you add the relations in the correct order, then you have the order you want. You can also delete one and add it again to put it at the end. Not the best but it’s something :slight_smile:
  • We are currently working on making them easily reorderable. So it’s coming :slight_smile:

Does this mean we can set relations as required fields now?

No it’s not part of the feature

Is it possible to create new item? Somethink like tags?

Do you mean creating them on the fly? If yes then no, it’s not part of the feature

1 Like

Not in this update but it is something we have planned. You can follow that feature request here:

If you want to follow the feature request for relation ordering, you can find that here. It is something the design is finished on but we haven’t started coding yet:

hello everyone, thanks and thanks

Updated documentation for these relations improvements is part of the Strapi docs v4.5.0 release (see announcement here)