-
Notifications
You must be signed in to change notification settings - Fork 5
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
Add unset on navigators #318
Conversation
unset() { | ||
const copy = this.copy() | ||
|
||
if (this.next.final) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is barely the same code as in the indexNav. Can we do something about it ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes this is exactly the same code as in IndexNav, and we could mutualize it in their common ancestor BaseNav.
But for comprehension sake, I think it is better to have two copies of this method, one that uses an index
which denotes an array access, and one that uses a key
which denotes a property access.
Codecov Report
@@ Coverage Diff @@
## dev #318 +/- ##
=========================================
- Coverage 97.17% 96.68% -0.5%
=========================================
Files 107 108 +1
Lines 425 452 +27
=========================================
+ Hits 413 437 +24
- Misses 12 15 +3
Continue to review full report at Codecov.
|
Description
Add
unset
operation on navigators, and use it inunset
.Issue : fix #305