MCPcopy Create free account
hub / github.com/ChromeDevTools/devtools-frontend / instance

Method instance

front_end/core/sdk/DOMModel.ts:2227–2236  ·  view source on GitHub ↗
(opts: {
    forceNew: boolean|null,
  } = {forceNew: null})

Source from the content-addressed store, hash-verified

2225 }
2226
2227 static instance(opts: {
2228 forceNew: boolean|null,
2229 } = {forceNew: null}): DOMModelUndoStack {
2230 const {forceNew} = opts;
2231 if (!domModelUndoStackInstance || forceNew) {
2232 domModelUndoStackInstance = new DOMModelUndoStack();
2233 }
2234
2235 return domModelUndoStackInstance;
2236 }
2237
2238 async markUndoableState(model: DOMModel, minorChange: boolean): Promise<void> {
2239 // Both minor and major changes get into the #stack, but minor updates are coalesced.

Callers 3

setDocumentMethod · 0.45
markUndoableStateMethod · 0.45
disposeMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected