patch-console
Advanced tools
Comparing version
{ | ||
"name": "patch-console", | ||
"version": "1.0.0", | ||
"version": "2.0.0", | ||
"description": "Patch console methods to intercept output", | ||
@@ -12,13 +12,16 @@ "license": "MIT", | ||
}, | ||
"main": "build", | ||
"types": "build/index.d.ts", | ||
"type": "module", | ||
"exports": "./dist/index.js", | ||
"engines": { | ||
"node": ">=10" | ||
"node": "^12.20.0 || ^14.13.1 || >=16.0.0" | ||
}, | ||
"scripts": { | ||
"prepare": "tsc", | ||
"test": "prettier --check src && tsc && xo && ava" | ||
"build": "tsc", | ||
"dev": "tsc --watch", | ||
"prepare": "npm run build", | ||
"pretest": "npm run build", | ||
"test": "prettier --check source && xo && ava" | ||
}, | ||
"files": [ | ||
"build" | ||
"dist" | ||
], | ||
@@ -35,18 +38,12 @@ "keywords": [ | ||
"devDependencies": { | ||
"@sindresorhus/tsconfig": "^0.7.0", | ||
"@types/node": "^14.0.13", | ||
"ava": "^3.9.0", | ||
"prettier": "^2.0.5", | ||
"@sindresorhus/tsconfig": "^2.0.0", | ||
"@types/node": "^17.0.14", | ||
"@vdemedes/prettier-config": "^2.0.1", | ||
"ava": "^4.0.1", | ||
"prettier": "^2.5.1", | ||
"sinon": "^9.0.2", | ||
"typescript": "^3.9.5", | ||
"xo": "^0.32.0" | ||
"typescript": "^4.5.5", | ||
"xo": "^0.47.0" | ||
}, | ||
"prettier": { | ||
"useTabs": true, | ||
"singleQuote": true, | ||
"quoteProps": "as-needed", | ||
"trailingComma": "none", | ||
"bracketSpacing": false, | ||
"arrowParens": "avoid" | ||
}, | ||
"prettier": "@vdemedes/prettier-config", | ||
"xo": { | ||
@@ -53,0 +50,0 @@ "prettier": true |
@@ -14,3 +14,3 @@ # patch-console  | ||
```js | ||
const patchConsole = require('patch-console'); | ||
import patchConsole from 'patch-console'; | ||
@@ -17,0 +17,0 @@ const restore = patchConsole((stream, data) => { |
5985
26.59%6
20%49
8.89%Yes
NaN8
14.29%