Iced: Upgrade `stretch`

Created on 5 Sep 2019  路  1Comment  路  Source: hecrj/iced

[Iced was built during May] using the 0.2 version of [stretch]. It seems that a new minor version was released recently, in July. We should consider upgrading.

At a first glance, the API has changed somewhat considerably. There is a new Stretch type that you have to keep around and mutate accordingly. I am guessing this allows (or will allow) for incremental computation of layouting, which is great!

However, in order to mutate the Stretch type and keep it in sync, we will need to implement a diffing strategy of nodes. This is mostly a solved problem, as React and Elm already do it, but some research will certainly be necessary and we will probably need to change the API a bit.

Also, as a naive first approach, we could simply recreate the Stretch type entirely every time.

In any case, benchmarking before upgrading is a good idea.

feature help wanted improvement question

Most helpful comment

As I'm probably to blame for this new API, it was mostly motivated by reusing memory and nodes across changes. The author seems to be interested in more incremental relayouting possibly in combination with salsa but that's currently beyond me!

Issues, performance numbers and general feedback appreciated!

>All comments

As I'm probably to blame for this new API, it was mostly motivated by reusing memory and nodes across changes. The author seems to be interested in more incremental relayouting possibly in combination with salsa but that's currently beyond me!

Issues, performance numbers and general feedback appreciated!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Newbytee picture Newbytee  路  4Comments

Shootertrex picture Shootertrex  路  3Comments

cetra3 picture cetra3  路  3Comments

johannesvollmer picture johannesvollmer  路  4Comments

Plecra picture Plecra  路  4Comments