luwes / luwes/js-diff-benchmark
snabbdom is broken on prepend/insert
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 69
- Forks
- 7
- PR merge metrics
- No merged PRs in 30d
Description
```js
// insert
diff(parent,[], [e1,e3,e5], null);
diff(parent,[...parent.childNodes],[e1,e2,e3,e4,e5], null);
parent.childNodes // e1, e2, e3, e5, e4
// prepend
diff(parent,[], [e4,e5], null);
diff(parent,[e4,e5],[e1,e2,e3,e4,e5], null);
parent.childNodes // e4, e5, e1, e2, e3
```
That is so regardless of the last argument.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the insert and prepend examples from the issue and inspect the DOM diffing implementation that they exercise. Compare the resulting parent.childNodes order with the expected sequences, then verify both cases after the fix.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100