Yoga layout engine version update?

Are there any plans to update to the latest Yoga version as part of Unity 6 (or Unity 7?)
It would be great to get support for things like gap or align-content: space-evenly

Hi @Sebioff, thank you for the question.

We have considered it but decided not to go ahead with it. Our Yoga implementation diverged significantly, and updating it might be risky.

That said, we could still implement gap and other properties on top of it. Are there other CSS properties you would like to see?

2 Likes

The main ones I can think of right now:

  • z-index
  • being able to set picking mode from USS (and maybe a variant of it that propagates down to children so you don’t have to set it on a dozen elements?)
  • align-content: space-between/space-around
  • row-gap, column-gap
4 Likes

Noted, thanks for sharing.

1 Like

+infinity to add gap support

Shame about the divergence. What sort of divergences? Will this end up locking unity/us out of modern improvements for half a decade or a decade to come…?

One more: aspect-ratio would be quite useful too

Yeah, I have a comment somewhere in our codebase that goes “the code below would be a lot less horrible if aspect-ratio was supported”