News for hackers. Stuff that matters.
Re:Why the Gov.uk Design System team changed the input type ... by patio11 on Friday February 28, 2020 @05:04AM (#22441734)
A fun edge case, of the million edge cases for credit cards:

If you have Japanese users, their browser/input method editor may send full-width characters by default, such as 4321 instead of 4321. You should probably honor those, but unless you wrote code to do this, you almost certainly won't. Even most Japanese sites are user-hostile here, either failing to detect them as numbers or telling the user "You wrote your number in full-width characters; please try again in half-width characters" despite them being trivially convertable.

(Disclaimer: this is professionally relevant to me and yes, Stripe Elements / Checkout do do the right thing here.)

Re:Why the Gov.uk Design System team changed the input type ... by kevin_thibedeau on Friday February 28, 2020 @11:39AM (#22443999)
For reference by others: You want to apply NFKC or NFKD Unicode normalization to collapse full-width Latin letters and digits to their usual form. This also widens half-width kana.