Skip to content

feat(#2515): add option to change grouped folders name with custom function #2521

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 3 commits into from
Nov 9, 2023

Conversation

Akmadan23
Copy link
Collaborator

Closes #2515

@@ -795,7 +795,10 @@ Appends a trailing slash to folder names.

*nvim-tree.renderer.group_empty*
Compact folders that only contain a single folder into one node.
Type: `boolean`, Default: `false`
Can be a custom function that takes one argument (the relative path
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
Can be a custom function that takes one argument (the relative path
Boolean or a function that takes single argument (the relative path

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I agree with all the corrections, I would just leave "one" instead of "single" since it's more consistent with two other occurrences of something like "the function takes one argument" throughout the docs

Copy link
Collaborator

Choose a reason for hiding this comment

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

Absolutely, consistency is the key. Thanks!

Copy link
Collaborator

@gegoune gegoune left a comment

Choose a reason for hiding this comment

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

Nit pick on documentation. Let's keep it impersonal and as short as possible while conveying necessary meaning.

Thanks for that PR! Interested to see what people will come up with.

Copy link
Member

@alex-courtis alex-courtis left a comment

Choose a reason for hiding this comment

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

Nice job, tested OK:

  • false
  • "invalid"
  • function returning number
  • function returning nil
  • function returning hardcoded string
  • function returning decorated

@Akmadan23 Akmadan23 requested a review from gegoune November 9, 2023 09:39
@Akmadan23 Akmadan23 merged commit a2aaf8b into master Nov 9, 2023
@Akmadan23 Akmadan23 deleted the 2515-group_empty-custom-function branch November 9, 2023 10:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

group_empty with custom label
3 participants