mirror of
https://github.com/zoriya/react-native-svg.git
synced 2025-12-05 22:56:11 +00:00
PR bumping packages, eslint, tsconfig, prettier and resolving all conflicts connected to it.
15 lines
399 B
TypeScript
15 lines
399 B
TypeScript
export function pickNotNil(object: { [prop: string]: unknown }) {
|
|
const result: { [prop: string]: unknown } = {};
|
|
for (const key in object) {
|
|
if (Object.prototype.hasOwnProperty.call(object, key)) {
|
|
const value = object[key];
|
|
if (value !== undefined && value !== null) {
|
|
result[key] = value;
|
|
}
|
|
}
|
|
}
|
|
return result;
|
|
}
|
|
|
|
export const idPattern = /#([^)]+)\)?$/;
|