Skip to content

Commit

Permalink
docs: only enable __coverage__ plugin in test env. (istanbuljs#280)
Browse files Browse the repository at this point in the history
  • Loading branch information
dtinth authored and bcoe committed Jun 15, 2016
1 parent 6de49bf commit 07d78c5
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,17 @@ the `sourceMaps` option to `inline`.
{
"babel": {
"presets": ["es2015"],
"plugins": ["__coverage__"]
"env": {
"test": {
"plugins": ["__coverage__"]
}
}
}
}
```

Note: With this configuration, the `__coverage__` will only be active when `NODE_ENV` or `BABEL_ENV` is `test`.

2. disable nyc's instrumentation and source-maps:

```json
Expand Down

0 comments on commit 07d78c5

Please sign in to comment.