MCPcopy Create free account
hub / github.com/microsoft/SandDance / getHiResTimestamp

Function getHiResTimestamp

docs/app/js/sanddance-app.js:54996–55004  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

54994parcelHelpers.defineInteropFlag(exports);
54995var process = require("process");
54996function getHiResTimestamp() {
54997 let timestamp;
54998 if (typeof window !== "undefined" && window.performance) timestamp = window.performance.now();
54999 else if (typeof process !== "undefined" && process.hrtime) {
55000 const timeParts = process.hrtime();
55001 timestamp = timeParts[0] * 1000 + timeParts[1] / 1e6;
55002 } else timestamp = Date.now();
55003 return timestamp;
55004}
55005exports.default = getHiResTimestamp;
55006
55007},{"process":"1RiLM","@parcel/transformer-js/src/esmodule-helpers.js":"jA2du"}],"6ULVt":[function(require,module,exports) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected