You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Snippet JSON files are serialized as a single line which makes them nearly impossible to manage via source control. When using tools like git any change results in an unusable diff since it appears 'everything' has changed and its difficult or impossible to manage conflicts
Describe the solution you'd like
When saving snippet json files to disk (or exporting), export them with indents.
I believe this is as simple as changing JSON.stringify(snippet) to JSON.stringify(snippet, null, 4) although I have not had a chance to test it:
Is your feature request related to a problem? Please describe.
Snippet JSON files are serialized as a single line which makes them nearly impossible to manage via source control. When using tools like git any change results in an unusable diff since it appears 'everything' has changed and its difficult or impossible to manage conflicts
Describe the solution you'd like
When saving snippet json files to disk (or exporting), export them with indents.
I believe this is as simple as changing
JSON.stringify(snippet)
toJSON.stringify(snippet, null, 4)
although I have not had a chance to test it:https://github.com/jupytercalpoly/jupyterlab-code-snippets/search?q=JSON.stringify
The text was updated successfully, but these errors were encountered: