Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface OrchestratorProps<DBSchema, StoreName>

The proptypes for Orchestrator.

Type parameters

Hierarchy

  • OrchestratorProps

Index

Properties

Optional context

context: DatabaseContext<DBSchema> | null

A context wrapper for a Database instance.

You must provide this if any of your components are instances of DynamicComponent for them to work as expected.

Optional initialSlug

initialSlug: string | null

The StepDefinition.slug to start the form on.

Defaults to the slug of the first StepDefinition in OrchestratorProps.steps.

Optional manageStepTransitions

manageStepTransitions: boolean | null

Whether the Orchestrator should manage StepDefinition transitions or you want to manage them yourself via routing, for example.

Defaults to true.

Optional onIncompleteStep

onIncompleteStep: ((keysMissingValues?: string[]) => void) | null

The callback to call when the Orchestrator has failed to transition to the next StepDefinition due to missing values.

Optional onNextStep

onNextStep: ((slug?: undefined | string) => void) | null

The callback to call when the Orchestrator is about to transition to the next StepDefinition.

This is called after the step has been submitted, and the Database transaction has completed. It is called immediately before it renders the new StepDefinition (if OrchestratorProps.manageStepTransitions is true).

Use this for any side effects that you might want when transitioning steps and for handling transitions to a StepDefinition.nextSlug that isn't managed by the Orchestrator.

param

The next StepDefinition.slug.

Optional provideDatabase

provideDatabase: boolean | null

Whether the Orchestrator should wrap the steps in a DatabaseProvider for you or you want to do that yourself.

You might want to disable this if you have pages that exist outside of the Orchestrator.

Defaults to true.

steps

steps: StepDefinition<DBSchema, StoreName>[]

An array of steps to render.

Generated using TypeDoc