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

feat: format functionality #28

Merged
merged 7 commits into from
May 15, 2024
Merged

feat: format functionality #28

merged 7 commits into from
May 15, 2024

Conversation

jdockerty
Copy link
Owner

@jdockerty jdockerty commented May 14, 2024

Closes #10

This adds what would be expected from some very basic formatting functionality. I.e. click the button and your Jsonnet is formatted in the same way that it would be using jsonnetfmt.

The handleFormat JavaScript is a little hacky, as the hx-swap/hx-post did not work in the same way as the other elements for replacing the textarea with the response from the server (#30). I'm not quite sure why this is, but what is done here works and is good enough for now 👍

@jdockerty jdockerty self-assigned this May 14, 2024
@jdockerty jdockerty marked this pull request as ready for review May 15, 2024 08:44
@jdockerty jdockerty merged commit c716450 into main May 15, 2024
1 check passed
@jdockerty jdockerty deleted the feat/formatting branch May 15, 2024 08:45
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.

Add format functionality
1 participant