UNPKG

@sap/generator-cap-project

Version:

Creates a new SAP Cloud Application Programming Model project.

15 lines (14 loc) 465 B
function getProperty(target, prop) { if (typeof prop === "string") { for (const [name, value] of Object.entries(target)) { if (prop.toLowerCase() === name.toLowerCase()) { return value; } } } return undefined; } export const proxyHeaders = (object) => new Proxy(object, { get: (target, prop) => getProperty(target, prop), has: (target, prop) => getProperty(target, prop) !== undefined });