MCPcopy
hub / github.com/cockpit-project/cockpit / forEach

Method forEach

pkg/lib/cockpit/dialog.tsx:738–743  ·  view source on GitHub ↗
(func: (val: DialogField<ArrayElement<T>>, index: number) => void)

Source from the content-addressed store, hash-verified

736 }
737
738 forEach(func: (val: DialogField<ArrayElement<T>>, index: number) => void): void {
739 const val = this.get();
740 if (Array.isArray(val)) {
741 val.forEach((_, i) => func(this.sub(i as keyof T) as DialogField<ArrayElement<T>>, i));
742 }
743 }
744
745 remove(index: number) {
746 const val = this.get();

Callers 15

getFilesFunction · 0.80
accounts-list.jsFile · 0.80
AccountsPageFunction · 0.80
get_defaultsFunction · 0.80
AccountLogsFunction · 0.80
parse_expireFunction · 0.80
getSeverityURLFunction · 0.80
setConfigMethod · 0.80
AboutCockpitModalFunction · 0.80
loadMethod · 0.80
renderMethod · 0.80

Calls 3

getMethod · 0.95
subMethod · 0.95
funcFunction · 0.85

Tested by

no test coverage detected