# Function produceDraftViewModelWithRequiredFields

- produceDraftViewModelWithRequiredFields<T extends ViewModel>(
  previousModel: T,
  newRequiredFields?: FieldDescription[],
  conditionalRequiredFieldKeys?: (keyof T)[],
  ): T

  #### Type Parameters

  - T extends ViewModel

  #### Parameters

  - previousModel: T
  - `Optional` newRequiredFields: FieldDescription[]
  - `Optional` conditionalRequiredFieldKeys: (keyof T)[]

  #### Returns T

  #### Deprecated

  Not used anywhere and performs a noop.

  - Defined in jslib/src/lib/utils/stepComponentHelpers/stepComponentHelpers.ts:468