-
Notifications
You must be signed in to change notification settings - Fork 45
Update README.md #20
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
Update README.md #20
Conversation
Fix node not defined error in README.md examples
Codecov Report
@@ Coverage Diff @@
## master #20 +/- ##
=======================================
Coverage 99.29% 99.29%
=======================================
Files 3 3
Lines 141 141
Branches 34 34
=======================================
Hits 140 140
Misses 1 1 Continue to review full report at Codecov.
|
README.md
Outdated
@@ -93,13 +93,13 @@ function* treeWalker(refresh) { | |||
|
|||
// Basing on the node openness state we are deciding if we need to render | |||
// the child nodes (if they exist). | |||
if (node.children.length !== 0 && isOpened) { | |||
if (children?.length !== 0 && isOpened) { |
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.
The same situation as in the previous comment.
@johannalee, thanks for the PR! Would be glad to merge it when all the flaws are fixed. |
Co-Authored-By: Vlad Rindevich <[email protected]>
Co-Authored-By: Vlad Rindevich <[email protected]>
@Lodin comments have been applied :) |
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.
Just one more fix 🙂 Sorry for delay
README.md
Outdated
// Since it is a stack structure, we need to put nodes we want to render | ||
// first to the end of the stack. | ||
for (let i = node.children.length - 1; i >= 0; i--) { | ||
for (let i = children?.length - 1; i >= 0; i--) { |
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.
You forgot this one 🙂 It is not necessary to check since we already check it above.
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.
LGTM, thanks!
Fix node not defined error in README.md examples
And type error in evaluating children.length