raygun4js
Version:
Raygun.io plugin for JavaScript
36 lines (32 loc) • 1.33 kB
HTML
<html>
<head>
<title>Raygun4JS with V2 API</title>
<script src="https://cdn.jsdelivr.net/npm/promise-polyfill@8/dist/polyfill.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/whatwg-fetch@3.0/dist/fetch.umd.min.js"></script>
<script src="/fixtures/common/instrumentXHRs.js"></script>
<script type="text/javascript">
!function(a,b,c,d,e,f,g,h){a.RaygunObject=e,a[e]=a[e]||function(){
(a[e].o=a[e].o||[]).push(arguments)},f=b.createElement(c),g=b.getElementsByTagName(c)[0],
f.async=1,f.src=d,g.parentNode.insertBefore(f,g),h=a.onerror,a.onerror=function(b,c,d,f,g){
h&&h(b,c,d,f,g),g||(g=new Error(b)),a[e].q=a[e].q||[],a[e].q.push({
e:g})}}(window,document,"script","/dist/raygun.js","rg4js");
</script>
</head>
<body>
<script type="text/javascript">
rg4js('apiKey', 'abcd==');
rg4js('enablePulse', true);
rg4js('options', {
allowInsecureSubmissions: true,
debugMode: true,
});
setTimeout(function () {
fetch('rumXhrStatusCodes.html');
fetch('rumXhrStatusCodes.html?foo=bar');
fetch('foo.html');
fetch('http://localhost:4567/fixtures/v2/rumXhrStatusCodes.html');
}, 500);
</script>
</body>
</html>