MCPcopy Create free account
hub / github.com/eclipsesource/jsonforms / removeId

Function removeId

packages/core/src/util/ids.ts:60–77  ·  view source on GitHub ↗
(id: string)

Source from the content-addressed store, hash-verified

58};
59
60export const removeId = (id: string) => {
61 const slot = idSlots.get(id);
62 if (slot === undefined) {
63 return false;
64 }
65 idSlots.delete(id);
66 const state = prefixStates.get(slot.prefix);
67 if (state !== undefined) {
68 state.used.delete(slot.index);
69 if (slot.index < state.next) {
70 state.next = slot.index;
71 }
72 if (state.used.size === 0) {
73 prefixStates.delete(slot.prefix);
74 }
75 }
76 return true;
77};
78
79export const clearAllIds = () => {
80 idSlots.clear();

Callers 1

ids.test.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…