https://github.com/catamphetamine/print-error
Javascript print error stack trace (pretty, terminal, html, markdown, etc)
https://github.com/catamphetamine/print-error
Last synced: about 1 month ago
JSON representation
Javascript print error stack trace (pretty, terminal, html, markdown, etc)
- Host: GitHub
- URL: https://github.com/catamphetamine/print-error
- Owner: catamphetamine
- License: mit
- Created: 2016-07-12T11:49:21.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2018-04-17T13:59:28.000Z (about 7 years ago)
- Last Synced: 2025-04-06T04:26:14.274Z (2 months ago)
- Language: JavaScript
- Size: 64.5 KB
- Stars: 1
- Watchers: 2
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# print-error
[](https://www.npmjs.com/package/print-error)
[](https://www.npmjs.com/package/print-error)
[](https://coveralls.io/r/catamphetamine/print-error?branch=master)Prints javascript error stack trace in different flavours:
* `pretty-print` coloured terminal ([demo](https://github.com/AriaMinaei/pretty-error))
* HTML ([demo](https://github.com/catamphetamine/print-error/tree/master/test/examples/error.html))
* markdown ([demo](https://github.com/catamphetamine/print-error/tree/master/test/examples/error.md))
* plain text ([demo](https://github.com/catamphetamine/print-error/tree/master/test/examples/error.txt))## Installation
```
npm install print-error --save
```## Usage
```js
import {
html,
htmlErrorStack,
HTML_ERROR_STACK_STYLE,
markdown,
terminal
} from 'print-error'// Outputs an HTML page.
html(new Error(), { fontSize: '16px' })// Outputs just the contents of the `