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 noUnusedLocals to tsconfig + fix the new alerts #6396
Conversation
static/panes/opt-view.ts
Outdated
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 was merged in a different PR, can ignore here.
return `Tree #${this.id}`; | ||
} | ||
|
||
private updateTitle() { |
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.
I can see it not being used, but it still confuses me. I guess it gets the container title directly from the factory?
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.
no...
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.
ah, it IS used, but by some black magic event handling.
So you should not remove these functions, maybe make them public to avoid being removed and then we can see how to make it bit more transparent these things are linked (but I'm not sure how (perhaps best to use an interface, I think the "normal" Pane's do use that))
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.
Good catch! The black magic isn't in event handling, I think it comes down to PaneRenaming
being completely untyped and in particular uses pane: any
to successfully call the Pane-private pane.updateTitle()
(which resolves to Tree.updateTitle
), and this is all hidden from TS. I'll revert the deletion, not sure I'll be able to properly fix the typing.
Are ... we good with this? I'd love to get more cool things merged but feel there's some tings to solve yet with the panes above, if I read it right? |
Sorry, I dropped this ball. Will return to this soon. |
…r#6396) <!-- THIS COMMENT IS INVISIBLE IN THE FINAL PR, BUT FEEL FREE TO REMOVE IT Thanks for taking the time to improve CE. We really appreciate it. Before opening the PR, please make sure that the tests & linter pass their checks, by running `make check`. In the best case scenario, you are also adding tests to back up your changes, but don't sweat it if you don't. We can discuss them at a later date. Feel free to append your name to the CONTRIBUTORS.md file Thanks again, we really appreciate this! -->
No description provided.