Files

13 lines
231 B
TypeScript

export function parseInt(rawInteger: number){
const integer = Number.parseInt(rawInteger);
if (Number.isNaN(integer) || !Number.isInteger(integer)) {
return null;
}
else {
return integer;
}
}