gitfix(tracker-profile): remove build code from index
This commit is contained in:
parent
732d31684b
commit
f88b95b59b
3 changed files with 1 additions and 19 deletions
1
tracker/tracker-profiler/.gitignore
vendored
1
tracker/tracker-profiler/.gitignore
vendored
|
|
@ -1,4 +1,5 @@
|
|||
node_modules
|
||||
npm-debug.log
|
||||
lib
|
||||
cjs
|
||||
.cache
|
||||
|
|
|
|||
|
|
@ -1,18 +0,0 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
const tracker_1 = require("@openreplay/tracker/cjs");
|
||||
function default_1() {
|
||||
return (app) => {
|
||||
if (app === null) {
|
||||
return (name) => (fn, thisArg) => thisArg === undefined ? fn : fn.bind(thisArg);
|
||||
}
|
||||
return (name) => (fn, thisArg) => (...args) => {
|
||||
const startTime = performance.now();
|
||||
const result = thisArg === undefined ? fn.apply(this, args) : fn.apply(thisArg, args);
|
||||
const duration = performance.now() - startTime;
|
||||
app.send(tracker_1.Messages.Profiler(name, duration, args.map(String).join(', '), String(result)));
|
||||
return result;
|
||||
};
|
||||
};
|
||||
}
|
||||
exports.default = default_1;
|
||||
|
|
@ -1 +0,0 @@
|
|||
{ "type": "commonjs" }
|
||||
Loading…
Add table
Reference in a new issue