-
-
Notifications
You must be signed in to change notification settings - Fork 7.6k
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
Jsonify is escaping characters #7229
Comments
It's the Go HTML template doing its ... job. Try
|
@bep Those don't work unfortunately. I had to resolve with a replace:
|
That function just delegates to Go's JSON package, so not sure what's going on ... But I'll reopen. |
There's nothing wrong with escaping those characters. See this roundtrip:
If you really don't want to escape
|
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
What version of Hugo are you using (
hugo version
)?Test:
{{ $testDict := dict "<any-key> " “value”}}
{{ $testDict | jsonify }}
gives:
{"\u003cany-key\u003e":“value”}
Is this a bug with jsonify or is there a hugo function I’m missing? Even a short term fix/hack would be greatly appreciated.
Thanks!
The text was updated successfully, but these errors were encountered: