source: trip-planner-front/node_modules/webpack-dev-server/lib/utils/tryParseInt.js@ 571e0df

Last change on this file since 571e0df was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 186 bytes
Line 
1'use strict';
2
3function tryParseInt(input) {
4 const output = parseInt(input, 10);
5
6 if (Number.isNaN(output)) {
7 return null;
8 }
9
10 return output;
11}
12
13module.exports = tryParseInt;
Note: See TracBrowser for help on using the repository browser.