Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 7938788

Browse files
committed
docs(README): improve README
1 parent ce7d264 commit 7938788

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

README.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,16 +91,17 @@ function add(a, b) {
9191
API
9292
---------------------------------------
9393
94-
unassert package exports three functions. `unassertAst` is the main function. `createVisitor` and `defaultOptions` are for customization.
94+
unassert package exports three functions. [`unassertAst`](https://github.com/unassert-js/unassert#const-modifiedast--unassertastast-options) is the main function. [`createVisitor`](https://github.com/unassert-js/unassert#const-visitor--createvisitoroptions) and [`defaultOptions`](https://github.com/unassert-js/unassert#const-options--defaultoptions) are for customization.
95+
9596
9697
### const modifiedAst = unassertAst(ast, options)
9798
9899
```javascript
99-
const { unassertAst, createVisitor, defaultOptions } = require('unassert')
100+
const { unassertAst } = require('unassert')
100101
```
101102
102103
```javascript
103-
import { unassertAst, createVisitor, defaultOptions } from 'unassert'
104+
import { unassertAst } from 'unassert'
104105
```
105106
106107
| return type |
@@ -188,7 +189,7 @@ in addition, unassert removes `console.assert` calls as well.
188189
* `console.assert(value, [message])`
189190
190191
191-
#### auto variable tracking
192+
#### Auto Variable Tracking
192193
193194
unassert automatically removes assertion calls based on their imported variable names.
194195
@@ -198,6 +199,8 @@ So if import declaration is as follows,
198199
199200
unassert removes all `strictAssert`, `ok`, `eq` calls.
200201
202+
Please see [customization example](https://github.com/unassert-js/unassert#example-1) for more details.
203+
201204
202205
### const visitor = createVisitor(options)
203206

0 commit comments

Comments
 (0)