MCPcopy
hub / github.com/graphql/graphiql / constructor

Method constructor

packages/monaco-graphql/src/workerManager.ts:23–33  ·  view source on GitHub ↗
(defaults: MonacoGraphQLAPI)

Source from the content-addressed store, hash-verified

21 private _client: Promise<GraphQLWorker> | null = null;
22
23 constructor(defaults: MonacoGraphQLAPI) {
24 this._defaults = defaults;
25 this._idleCheckInterval = window.setInterval(
26 () => this._checkIfIdle(),
27 30 * 1000,
28 );
29 // this is where we re-start the worker on config changes
30 this._configChangeListener = this._defaults.onDidChange(() => {
31 this._stopWorker();
32 });
33 }
34
35 private _stopWorker(): void {
36 if (this._worker) {

Callers

nothing calls this directly

Calls 3

_checkIfIdleMethod · 0.95
_stopWorkerMethod · 0.95
onDidChangeMethod · 0.45

Tested by

no test coverage detected