-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Customize object names #339
Comments
Nice idea, I like it. this way you can give a more informative summary of what's in an object. Your PR looks neat. A few remarks:
|
@chromey any news on this? |
I realized that my implementation has an issue with the editor's lifecycle. That is, the object's name would not update when its properties change. Probably easy to fix, but it disappeared in my backlog. |
Thanks for your feedback. Would be nice if you could find a fix for that. If it becomes too complicated, it may be interesting to see whether this will be easier to implement in the upcoming |
Hi, Thank you for your help :) |
I've opened PR #617 concerning this issue. |
I'd like to have the possibility to customize what is rendered as the name of a collapsed object. For example, if I have an array with lots of objects with an identifying field such as 'id' or 'name', I'd rather display that instead of the default field count.
I have created a PR that accomplishes this with a callback "onObjectName" that can be passed as an additional option. The callback gets handed the object's path and child nodes. Returning null from the callback falls back to displaying the field count.
#338
Awesome project btw, keep going!
The text was updated successfully, but these errors were encountered: