Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
microsoft
GitHub Repository: microsoft/vscode
Path: blob/main/src/vs/workbench/contrib/notebook/browser/notebookLogger.ts
3296 views
1
/*---------------------------------------------------------------------------------------------
2
* Copyright (c) Microsoft Corporation. All rights reserved.
3
* Licensed under the MIT License. See License.txt in the project root for license information.
4
*--------------------------------------------------------------------------------------------*/
5
6
// import * as DOM from 'vs/base/browser/dom';
7
8
class NotebookLogger {
9
constructor() {
10
this._domFrameLog();
11
}
12
private _frameId = 0;
13
private _domFrameLog() {
14
// DOM.scheduleAtNextAnimationFrame(() => {
15
// this._frameId++;
16
17
// this._domFrameLog();
18
// }, 1000000);
19
}
20
21
debug(...args: any[]) {
22
const date = new Date();
23
console.log(`${date.getSeconds()}:${date.getMilliseconds().toString().padStart(3, '0')}`, `frame #${this._frameId}: `, ...args);
24
}
25
}
26
27
const instance = new NotebookLogger();
28
export function notebookDebug(...args: any[]) {
29
instance.debug(...args);
30
}
31
32
33