backtrace-js
Advanced tools
Comparing version 0.0.4 to 0.0.5
@@ -5,6 +5,6 @@ exports.report = report; | ||
var myVersion = "0.0.0"; // should match package.json | ||
var myVersion = "0.0.5"; // should match package.json | ||
var initialized = false; | ||
var uuidArray = new Uint8Array(16); | ||
var crypto = window.crypto; | ||
var crypto = window.crypto || window.msCrypto; | ||
var pageStartTime = new Date(); | ||
@@ -58,3 +58,7 @@ var stackLineRe = /\s+at (.+) \((.+):(\d+):(\d+)\)/; | ||
function onGlobalError(ev) { | ||
report(ev.error); | ||
if (ev.error) { | ||
report(ev.error); | ||
} else { | ||
report(new Error(ev.message || "unknown")); | ||
} | ||
} | ||
@@ -61,0 +65,0 @@ } |
{ | ||
"name": "backtrace-js", | ||
"version": "0.0.4", | ||
"version": "0.0.5", | ||
"description": "Backtrace.io error reporting tool for client-side applications", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -9,13 +9,17 @@ # backtrace-js | ||
// Import backtrace-js with your favorite package manager. | ||
import * as bt from 'backtrace-js' | ||
import * as bt from 'backtrace-js'; | ||
bt.initialize({ | ||
endpoint: "https://console.backtrace.io", | ||
token: "51cc8e69c5b62fa8c72dc963e730f1e8eacbd243aeafc35d08d05ded9a024121", | ||
}) | ||
endpoint: `https://console.backtrace.io:${BACKTRACE_PORT}`, | ||
token: '51cc8e69c5b62fa8c72dc963e730f1e8eacbd243aeafc35d08d05ded9a024121', | ||
}); | ||
// Later, when you have an error: | ||
bt.report(new Error("something broke")); | ||
bt.report(new Error('something broke')); | ||
``` | ||
## Documentation | ||
See [backtrace-node](https://github.com/backtrace-labs/backtrace-node#documentation)'s documentation. | ||
## Testing | ||
@@ -28,1 +32,8 @@ | ||
``` | ||
## Making a release | ||
1. Update package.json with version number | ||
2. Update `var myVersion = "x.y.z";` to match package.json | ||
3. Create a git tag | ||
4. `npm publish` |
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
10868
307
38
6
2