Skip to content

Fix JSON input value serialization in template#6

Open
fullonic wants to merge 1 commit intodevfrom
fix/cast-json-value-to-json-instead-to-string
Open

Fix JSON input value serialization in template#6
fullonic wants to merge 1 commit intodevfrom
fix/cast-json-value-to-json-instead-to-string

Conversation

@fullonic
Copy link
Collaborator

@fullonic fullonic commented Oct 8, 2025

This fixes issues when the JSON contains a single quote (') that could be converted into a double quote (") and consequently breaks the input tag's value attribute. Using tojson ensures that the value is escaped before injecting it into the HTML input form.

@fullonic fullonic self-assigned this Oct 8, 2025
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.

1 participant