MCPcopy
hub / github.com/xaboy/form-create / rm

Function rm

packages/core/src/factory/context.js:228–250  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

226 this.ctrlRule = [];
227 },
228 rm() {
229 const _rm = () => {
230 let index = this.root.indexOf(this.origin);
231 if (index > -1) {
232 this.root.splice(index, 1);
233 this.$handle && this.$handle.refresh();
234 }
235 }
236 if (this.deleted) {
237 _rm();
238 return;
239 }
240 this.$handle.noWatch(() => {
241 this.$handle.deferSyncValue(() => {
242 this.rmCtrl();
243 _rm();
244 this.$handle.rmCtx(this);
245 extend(this, {
246 root: []
247 });
248 }, this.input);
249 });
250 },
251 update(handle, init) {
252 extend(this, {
253 deleted: false,

Callers

nothing calls this directly

Calls 3

_rmFunction · 0.85
extendFunction · 0.85
deferSyncValueMethod · 0.80

Tested by

no test coverage detected