create a type from an object
const iconMap = {
angleDoubleRight: "angleDoubleRight.svg",
angleRight: "angleRight.svg",
assets: "assets.svg",
barChart: "barChart.svg",
cancel: "cancel.svg",
chevronDown: "chevronDown.svg",
dotChart: "dotChart.svg",
dotMenu: "dotMenu.svg",
horizontalDots: "horizontalDots.svg"
//...
};
type IconMapMember = keyof typeof iconMap;
// type IconMapMember = "angleDoubleRight" | "angleRight" | "assets" | "barChart"
// | "cancel" | "chevronDown" | "dotChart" | "dotMenu" | "horizontalDots" ...