Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Reconversion] Get back to rangeToStructure() #10747

Closed
Reinmar opened this issue Oct 25, 2021 · 1 comment
Closed

[Reconversion] Get back to rangeToStructure() #10747

Reinmar opened this issue Oct 25, 2021 · 1 comment
Assignees
Labels
squad:core Issue to be handled by the Core team. type:task This issue reports a chore (non-production change) and other types of "todos".

Comments

@Reinmar
Copy link
Member

Reinmar commented Oct 25, 2021

Part of #10294.

  • Recap of what we had.
  • List of problematic cases. Write them down.
  • Reflect on how it applies to the new reality.
@Reinmar Reinmar added type:task This issue reports a chore (non-production change) and other types of "todos". squad:core Issue to be handled by the Core team. labels Oct 25, 2021
@niegowski niegowski self-assigned this Oct 25, 2021
@niegowski
Copy link
Contributor

The old PoC was in i/9407-list-reconversion branch with:

  • A first rough implementation of re-conversion with the usage of slots. It also included slotFor( 'self' ) to be able to trigger the conversion of the attribute that results as a wrapper element around the element with the converted attribute. This was mainly rewritten in the feature branch. The slotFor( 'self' ) is not yet ported.
  • MappedRange (temporary name) - The concept of a collection of flat ranges that update their start and end according to the Differ output. Those are reacting to a specific list of attributes to keep a consecutive list of list elements as a single list. This part is working pretty well, it also has automatic tests. This is supposed to track where are the ranges considered as a virtual items in the model. Those were expected to reduce changes provided by the Differ to replace some of them with the re-conversion items (but failed in cases of joining/splitting lists).
  • The Differ providing more details for the DiffItem: element reference and map of attributes. This was used by MappedRange to find out which changes should affect the range.
  • Some prototypes of low-level conversion handlers for the lists (a base for future downcast helper).
  • The removing of view elements was a hybrid solution that used element/list reference to remove the whole view element (instead of mapping positions before/after the removed element).

The biggest problem (besides the roughness of that implementation) was how to reduce Differ's changes so they would contain insertRange and removeRange in the proper sequence.

@Reinmar Reinmar closed this as completed Nov 5, 2021
@Reinmar Reinmar added this to the iteration 49 milestone Nov 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
squad:core Issue to be handled by the Core team. type:task This issue reports a chore (non-production change) and other types of "todos".
Projects
None yet
Development

No branches or pull requests

2 participants