Skip to content

How to access nvimtree state? Want to toggle on focus, but not if already open. #1683

Answered by alex-courtis
rtviii asked this question in Q&A
Discussion options

You must be logged in to vote

You can use events to determine the state: :help nvim-tree-events

You could listen for Event.TreeOpen and Event.TreeClose and record state. It would be best to maintain state per tab.

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Answer selected by rtviii
Comment options

You must be logged in to vote
2 replies
@rtviii
Comment options

@alex-courtis
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
2 participants
Converted from issue

This discussion was converted from issue #1681 on October 24, 2022 03:39.