infra: enable radix eslint rule (#3261)

This commit is contained in:
Alexandr Garbuzov 2023-10-13 22:21:12 +03:00 committed by GitHub
parent 1c07f4142c
commit b753d49158
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -99,7 +99,7 @@
"location": "start"
}],
"no-with": "warn",
// "radix": "warn",
"radix": "warn",
// "vars-on-top": "error",
// Enforces the style of wrapped functions

View file

@ -232,7 +232,7 @@ const parseArray = (str) => {
*/
const clampValue = (number, min, max) => {
// @ts-ignore
if (Number.isNaN(parseInt(number))) {
if (Number.isNaN(parseInt(number, 10))) {
return min;
}
return Math.max(min, Math.min(number, max));