Skip to content

docs: complete API calls for commands #2556

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

Merged
merged 1 commit into from
Nov 25, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions doc/nvim-tree-lua.txt
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ via |nvim-tree.on_attach| e.g. >

Opens the tree. See |nvim-tree-api.tree.open()|

Calls: `api.tree.open({ path = "<arg>" })`
Calls: `api.tree.open({ path = "<args>" })`

*:NvimTreeClose*

Expand All @@ -244,13 +244,13 @@ via |nvim-tree.on_attach| e.g. >

Open or close the tree. See |nvim-tree-api.tree.toggle()|

Calls: `api.tree.toggle({ path = "<arg>" })`
Calls: `api.tree.toggle({ path = "<args>", find_file = false, update_root = false, focus = true, })`

*:NvimTreeFocus*

Open the tree if it is closed, and then focus on the tree.

See |nvim-tree-api.tree.toggle()|
See |nvim-tree-api.tree.focus()|
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was incorrect, others are just clarifications.


Calls: `api.tree.focus()`

Expand All @@ -272,7 +272,7 @@ via |nvim-tree.on_attach| e.g. >

See |nvim-tree-api.tree.find_file()|

Calls: `api.tree.find_file { open = true, update_root = <bang> }`
Calls: `api.tree.find_file({ update_root = <bang>, open = true, focus = true, })`

*:NvimTreeFindFileToggle*

Expand All @@ -284,7 +284,7 @@ via |nvim-tree.on_attach| e.g. >

See |nvim-tree-api.tree.toggle()|

Calls: `api.tree.toggle { find_file = true, focus = true, path = "<arg>", update_root = <bang> }`
Calls: `api.tree.toggle({ path = "<args>", update_root = <bang>, find_file = true, focus = true, })`

*:NvimTreeClipboard*

Expand Down