Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/transitive-bullshit/is-acronym
Determines whether a given string is a common English acronym.
https://github.com/transitive-bullshit/is-acronym
acronym acronyms english
Last synced: 2 months ago
JSON representation
Determines whether a given string is a common English acronym.
- Host: GitHub
- URL: https://github.com/transitive-bullshit/is-acronym
- Owner: transitive-bullshit
- Created: 2018-08-16T17:55:18.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2018-08-16T17:58:09.000Z (over 6 years ago)
- Last Synced: 2024-10-20T01:08:44.768Z (2 months ago)
- Topics: acronym, acronyms, english
- Language: JavaScript
- Size: 68.4 KB
- Stars: 6
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# is-acronym
> Determines whether a given string is a common English acronym.
[![NPM](https://img.shields.io/npm/v/is-acronym.svg)](https://www.npmjs.com/package/is-acronym) [![Build Status](https://travis-ci.com/transitive-bullshit/is-acronym.svg?branch=master)](https://travis-ci.com/transitive-bullshit/is-acronym) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)
## Install
This module requires `node >= 4`.
```bash
npm install --save is-acronym
```## Usage
```js
const isAcronym = require('is-acronym')isAcronym('CDN') // true
isAcronym('FPS') // trueisAcronym('cdn') // false
isAcronym('fps') // false
isAcronym(' TEST ') // false
```## API
### [isAcronym](https://github.com/transitive-bullshit/is-acronym/blob/aa7a523fe4ca884e81ae12dddd868e609484b341/index.js#L14-L19)
Determines whether a given string is a common English acronym.
Type: `function (text): boolean`
- `text` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** String to test.
## Related
- [retext-redundant-acronyms](https://github.com/retextjs/retext-redundant-acronyms) - Check for redundant acronyms (ATM machine).
## License
MIT © [Travis Fischer](https://github.com/transitive-bullshit)