kutt
Version:
Node.js & browser (TypeScript) client for Kutt url shortener
17 lines • 481 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.reviver = void 0;
const DATE_KEYS = ["created_at", "updated_at"];
/**
*
* @param key
* @param value
*/
// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types,@typescript-eslint/no-explicit-any
function reviver(key, value) {
if (DATE_KEYS.includes(key))
return new Date(value);
return value;
}
exports.reviver = reviver;
//# sourceMappingURL=utils.js.map