0.0.2 • Published 7 years ago

zliq-stacktrace v0.0.2

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

ZLIQ-Stacktrace

ZLIQ

Wrapper around Stacktrace.js to easyly add it to zliq. It will remove calls inside zliq from the stacktrace, making it easier to read.

Quickstart

To use ZLIQ-stacktrace in your project, first install it as an dependency:

$ npm install --save zliq-stacktrace

Then activate the stacktrace shrinking.

import {shrinkStacktrace} from 'zliq-stacktrace';

// shrinkStacktrace returns an errorhandler
window.onerror = (messageOrEvent, source, lineno, colno, error) => {
    return shrinkStacktrace(
        /node_modules\/zliq/, // blackList (optional)
        /.*/ // whitelist (optional)
    )(error);
}