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

Apostrophe missing in message text with variable #316

Open
m-i-0 opened this issue Sep 27, 2023 · 0 comments
Open

Apostrophe missing in message text with variable #316

m-i-0 opened this issue Sep 27, 2023 · 0 comments

Comments

@m-i-0
Copy link

m-i-0 commented Sep 27, 2023

Simple issue - if text contains apostrophe and has placeholder for variable, the apostrophe wont display and variable wont be replaced until second apostrophe is added, which is error prone (because without variable, only 1 apostrophe is needed):

messages.properties:

test.simple = Lorem i'psum
test.variable.nok= Lorem i'psum {0}
test.variable.ok = Lorem i''psum {0}

test.html:

<span th:text="#{test.simple}"></span>
<span th:text="#{test.variable.nok(${val})}"></span>
<span th:text="#{test.variable.ok(${val})}"></span>

Tested on Spring Boot + Thymeleaf 2.7.14 - 2.7.16.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant