Skip to content

Commit

Permalink
Clearer documentation for parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
dpilafian committed Mar 26, 2022
1 parent 5dff8da commit d94239b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ import { prettyPrintJson } from 'pretty-print-json';
```
Or for older CommonJS/UMD environments:
```javascript
const { prettyPrintJson } = require('pretty-print-json'); //deprecated
const { prettyPrintJson } = require('pretty-print-json'); //deprecated -- use ES modules instead
```

## 3) Usage
Expand All @@ -52,7 +52,7 @@ const html = prettyPrintJson.toHtml(data, options?);
<pre id=account class=json-container></pre>
```
##### JavaScript:
Pass data into `prettyPrintJson.toHtml()` and display the results.
Pass data into `prettyPrintJson.toHtml(data, options)` and display the results.
```javascript
const data = { active: true, mode: '🚃', codes: [48348, 28923, 39080], city: 'London' };
const elem = document.getElementById('account');
Expand Down

0 comments on commit d94239b

Please sign in to comment.