-
-
Notifications
You must be signed in to change notification settings - Fork 73
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
JSON / YAML auto-formatting #10
Comments
Certainly, I will try to add this feature in the next version. |
Auto recognizing sounds good. I would have the formatting be optional, enabled via a button though, since some people may not want to save formatted code to their ZNode. |
Using Zoonavigator heavily right now and wondering again about auto-formatting. Did you end up doing anything with this? For me, every time I open a znode the first thing I do is change the format to JSON then hit reformat. Doing this over and over, it gets old :) |
Yes and no. You shouldn't have to change the format every time you open a znode as ZooNavigator now remembers which format was used for which node. However, there is no option that reformats the data for you automatically. I refrain from putting it in as a default option because for some it might be more reasonable to keep the data small rather than nice. I could, however, put it in as another toggle button or sth. Would that work for you? |
I agree, that auto-formatting would be bad for some cases. It would be nice to have as a toggle though, so when I just want to browse data I can see it formatted without having to manually format. It might make sense if auto-formatted data doesn't prompt a user to save though, only a change made by the user should prompt to save. That way the auto-formatted data is never saved automatically. |
I see. I haven't really thought about just browsing the nodes. Rather, I thought about it more like Format on save feature. I agree with you tho, it would certainly be a nice thing to have. I'm reopening this and hopefully will be able to look into it soon. It might be tricky to implement using the current formatter exactly because of what you've described, prompting user to save etc. |
I really like the JSON / YAML modes and was wondering if it would make sense to offer an auto-formatting option based on the mode where text is formatted to be more readable according to the mode.
The text was updated successfully, but these errors were encountered: