Replies: 2 comments
-
I would do this instead: |
Beta Was this translation helpful? Give feedback.
0 replies
-
You could do |
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
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Just ran into this this scenario. Using HTML input with pattern regexp. Need to validate length of string. Used
pattern="\d{4}"
. Took me a while to work out why it wasn't working, Svelte compiles it topattern="\d4"
. The only way to get around this is use the uglierpattern="\d{'{'}4{'}'}"
syntax to output literal curly braces.May I suggest:
pattern="\d\{4}"
It's not really a bug per-se, so though it would be best to open thread here, but if you think it would be better as an issue, I'm happy to convert it to one.
Beta Was this translation helpful? Give feedback.
All reactions