slice string

This commit is contained in:
Primakov Alexandr Alexandrovich 2022-11-27 19:00:10 +03:00
parent 36d2d2ac73
commit ae7b0a6b7f

View File

@ -19,7 +19,7 @@ export const Keyboard = ({ onChange }) => {
if (typeof key === 'string') { if (typeof key === 'string') {
onChange(v => v + key.toUpperCase()); onChange(v => v + key.toUpperCase());
} else { } else {
onChange(v => v.split('').slice(0, -1).join('')) onChange(v => v.slice(0, -1))
} }
} }
return ( return (