Skip to content

Commit

Permalink
Add ESM usage to README
Browse files Browse the repository at this point in the history
  • Loading branch information
vassudanagunta authored and jordanbtucker committed Aug 9, 2022
1 parent 5a2740f commit 4952108
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions README.md
Expand Up @@ -78,10 +78,16 @@ specification](https://json5.github.io/json5-spec/).
npm install json5
```

CJS:
```js
const JSON5 = require('json5')
```

ESM:
```js
import JSON5 from 'json5'
```

### Browsers
```html
<script src="https://unpkg.com/json5@^2.0.0/dist/index.min.js"></script>
Expand Down

0 comments on commit 4952108

Please sign in to comment.