Files
super-app/App/common/utilities/RecordUtils.ts
2024-04-25 11:09:24 +00:00

7 lines
201 B
TypeScript

export const useAsRecord = (map?: Map<string, string> | null) => {
const myRecord: Record<string, string> = {};
map?.forEach((value, key) => {
myRecord[key] = value;
});
return myRecord;
};