UNPKG

hytescript.js

Version:

A package for programming anything you want with ease.

16 lines (15 loc) 483 B
module.exports = { description: 'Checks if a string is a float number.', usage: 'string', parameters: [ { name: 'String', description: 'The string to be checked.', optional: 'false', defaultValue: 'none' } ], run: async (d, string) => { if (string == undefined) return new d.error("required", d, 'string') return isNaN(string) ? 'NaN' : !Number.isInteger(Number(string)); }};