mirror of
https://github.com/wanderer-industries/wanderer
synced 2025-12-08 08:45:37 +00:00
9 lines
275 B
TypeScript
9 lines
275 B
TypeScript
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
export const omit = <T extends Record<string, any>, K extends keyof T>(obj: T, keys: K[]): Omit<T, K> => {
|
|
const result = { ...obj };
|
|
for (const key of keys) {
|
|
delete result[key];
|
|
}
|
|
return result;
|
|
};
|