[**@wocart/theme v4.1.0**](../../README)

***

[@wocart/theme](../../README) / [index](../README) / InferProps

# Type Alias: InferProps\<D\>

> **InferProps**\<`D`\> = `Omit`\<`FieldProps`\<`D`\>, keyof `LoadedProps`\<`D`\>\> & `LoadedProps`\<`D`\>

The props `InstanceView` passes to a definition's component, derived from
the definition so the component and its fields cannot drift apart:

```ts
type Props = InferProps<typeof heroDefinition>;
```

A field with a `default` is always present; any other field may be absent
(no value, no content, or reported as invalid). Whatever `load` returns is
merged over the fields, as the renderer does at runtime. Use `defineComponent`
so field keys, kinds and select options keep their literal types.

## Type Parameters

### D

`D` *extends* [`ComponentDefinition`](../interfaces/ComponentDefinition)
