Skip to content
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

Support auto-formatting syntax #133

Open
tameeshB opened this issue May 10, 2022 · 2 comments
Open

Support auto-formatting syntax #133

tameeshB opened this issue May 10, 2022 · 2 comments

Comments

@tameeshB
Copy link

tameeshB commented May 10, 2022

It would be nice to have a feature where, if enabled, the saved file/s would have formatting.
For example, json formatting, traceback formatting and auto-formatting any code that is pasted.

How I imagine this could be implemented would be by adding a checkbox to the form (check to auto-format) and in the backend, we format the contents before saving it as a file.

@chriskuehl
Copy link
Owner

I think this would be really useful. My main concern is that people often paste snippets of text that don't necessarily have correct syntax (or the correctly-identified language) and these may format in really poor ways depending on the implementation. If there was a way for users to see the formatted text before submitting that might help the UX a lot (for example, if the formatting was done client-side with a button click prior to submission).

@tameeshB
Copy link
Author

My idea was to let the user pasting the text decide if they want to format it using a checkbox on the form. This way, if they know that they are pasting something poorly indented/formatted like a raw JSON, the shared version would be formatted.

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

No branches or pull requests

2 participants