An open API service indexing awesome lists of open source software.

https://github.com/ttys026/reserved-tokens

reserved-tokens in javascript
https://github.com/ttys026/reserved-tokens

Last synced: about 1 year ago
JSON representation

reserved-tokens in javascript

Awesome Lists containing this project

README

          

### reserved-tokens

#### Installation

```
npm install reserved-tokens
```

#### API

```javascript
import { isReserved, getValidVarName } from 'reserved-tokens';
const valid = !isReserved(word);
const validName = getValidVarName(word);
```

This lib uses the latest word map from [v8 scanner](https://github.com/v8/v8/blob/master/src/parsing/scanner-inl.h#L18)