Usage: hasProperties(obj, ["a", "b"]); // Gives type Record hasProperties(obj, ["a", "b"] as const); // Gives type Record<"a" | "b", unknown>