import { omit } from "https://deno.land/x/30_seconds_of_typescript@v1.0.1/util.ts";
Omits the key-value pairs corresponding to the given keys from an object.
Use Object.keys(obj)
, Array.prototype.filter()
and Array.prototype.includes()
to remove the provided keys.
Use Array.prototype.reduce()
to convert the filtered keys back to an object with the corresponding key-value pairs.