UNPKG

@polygonjs/polygonjs

Version:

node-based WebGL 3D engine https://polygonjs.com

11 lines (10 loc) 233 B
"use strict"; export function dictionaryInvert(dict) { const invertedDict = {}; const keys = Object.keys(dict); for (const key of keys) { const value = dict[key]; invertedDict[value] = key; } return invertedDict; }