[API reference](https://evolu.dev/docs/api-reference) › [@evolu/common](https://evolu.dev/docs/api-reference/common) › [Type](https://evolu.dev/docs/api-reference/common/Type) › partial

```ts
function partial<Props>(
  props: Props,
): ObjectType<{ [K in string | number | symbol]: OptionalType<Props[K]> }>;
```

Defined in: [packages/common/src/Type.ts:4404](https://github.com/evoluhq/evolu/blob/e7144e2bbe9069362b62dec1b64a8aa922b8f1b0/packages/common/src/Type.ts#L4404)

Creates a partial object type where all properties are optional.

This is useful when we want to validate an object in which none of the keys
are required, but if they are present they must conform to their
corresponding Types.

### Example

```ts
const PartialUser = partial({
  name: NonEmptyString,
  age: PositiveNumber,
});

// Valid: an empty object is accepted
PartialUser.from({});

// Valid: when provided, the properties must validate correctly
PartialUser.from({ name: "Alice" });

// Invalid: if a property is present but fails validation it returns an error
PartialUser.from({ age: -5 });
```