UNPKG

purespectrum-lib

Version:

shared code between front and backend projects

15 lines (14 loc) 408 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getEnumByValue = exports.clone = void 0; function clone(object) { return JSON.parse(JSON.stringify(object)); } exports.clone = clone; function getEnumByValue(enumDef, value) { if (Object.values(enumDef).includes(value)) { return value; } return undefined; } exports.getEnumByValue = getEnumByValue;