Replies: 1 comment
-
Sounds like a question for flask-assets, not for flask... |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
So in my production environment, i use Bundle imported from flask_assets.
Then in my JavaScript file, I have the following
Suppose that today's date is 6/8/2023. The englishDate is supposed to have a string value of "
08 Jun, 2023
". However, the value it got on production after the bundle is "08Jun,2023
". All the spaces within the string is removed.I checked the bundled file, it turned out that the spaces are remove in the code when being bundled. The last line became
However, If I don't use variables inside the string enclosed by backticks (`). Such as
All the spaces in the string will be preserved.
It seems like this issue only happened when a variable is used within a template string. All the spaces followed by the variable will be removed by the bundler.
Can anyone replicate it and let me know?
Beta Was this translation helpful? Give feedback.
All reactions