@grafana/faro-web-sdk
Version:
Faro instrumentations, metas, transports for web.
18 lines • 720 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.ConsoleTransport = void 0;
const faro_core_1 = require("@grafana/faro-core");
class ConsoleTransport extends faro_core_1.BaseTransport {
constructor(options = {}) {
super();
this.options = options;
this.name = '@grafana/faro-web-sdk:transport-console';
this.version = faro_core_1.VERSION;
}
send(item) {
var _a;
return this.unpatchedConsole[(_a = this.options.level) !== null && _a !== void 0 ? _a : faro_core_1.LogLevel.DEBUG]('New event', (0, faro_core_1.getTransportBody)([item]));
}
}
exports.ConsoleTransport = ConsoleTransport;
//# sourceMappingURL=transport.js.map