https://github.com/hannasdev/data-type-tool-belt
A bunch of utilities for working with different data types
https://github.com/hannasdev/data-type-tool-belt
Last synced: about 1 year ago
JSON representation
A bunch of utilities for working with different data types
- Host: GitHub
- URL: https://github.com/hannasdev/data-type-tool-belt
- Owner: hannasdev
- Created: 2019-04-24T08:41:30.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2019-04-26T10:06:45.000Z (about 7 years ago)
- Last Synced: 2024-08-08T19:16:06.409Z (almost 2 years ago)
- Language: JavaScript
- Size: 9.77 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Data Type Tool Belt
## Installation
```terminal
npm i @gothbarbie/data-type-tool-belt
```
## Usage
```javascript
const { isNumber } = require('@gothbarbie/data-type-tool-belt')
// returns true
const result = isNumber('0123456')
// returns false
const result = isNumber('0123 456')
```
## String
### isNumber
- Returns **true** if a string contains only digits.
- Returns **false** if it contains anything else (including spaces).