MCPcopy Index your code
hub / github.com/devcontainers/cli / pick

Function pick

src/spec-node/imageMetadata.ts:318–325  ·  view source on GitHub ↗
(obj: T, keys: K[])

Source from the content-addressed store, hash-verified

316}
317
318function pick<T extends object, K extends keyof T>(obj: T, keys: K[]) {
319 return keys.reduce((res, key) => {
320 if (key in obj) {
321 res[key] = obj[key];
322 }
323 return res;
324 }, {} as Pick<T, K>);
325}
326
327export interface ImageBuildInfo {
328 user: string;

Callers 2

getDevcontainerMetadataFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected