UNPKG

@popperjs/core

Version:

Tooltip and Popover Positioning Engine

12 lines (10 loc) 246 B
// @flow export default function expandToHashMap< T: number | string | boolean, K: string >(value: T, keys: Array<K>): { [key: string]: T } { return keys.reduce((hashMap, key) => { hashMap[key] = value; return hashMap; }, {}); }