MCPcopy
hub / github.com/GrapesJS/grapesjs / remove

Method remove

packages/core/src/commands/index.ts:306–315  ·  view source on GitHub ↗

* Remove command from the collection * @param {string} id Command's ID * @return {this}

(id: string)

Source from the content-addressed store, hash-verified

304 * @return {this}
305 */
306 remove(id: string) {
307 if (this.isActive(id)) {
308 this.stopCommand(this.get(id), { force: true });
309 }
310
311 delete this.active[id];
312 delete this.commands[id];
313
314 return this;
315 }
316
317 /**
318 * Get command by ID

Callers 3

buildMethod · 0.45
runMethod · 0.45
runMethod · 0.45

Calls 3

isActiveMethod · 0.95
stopCommandMethod · 0.95
getMethod · 0.95

Tested by

no test coverage detected