Step Change Callback (onStepChange)
Concept
| Description | The onStepChange callback fires whenever the importer navigates to a new step. Enables you to update your application's URL or send analytics events to track funnel progression. |
| Type | (step: string) => void |
| Run event | Fires when a step first renders. |
Step identifiers
The step argument passed to onStepChange is one of the following strings:
| Step identifier | When it fires |
|---|---|
upload | The upload step renders |
sheet-selection | The sheet selection step renders |
header-selection | The header selection step renders |
join-sheets | The join sheets step renders |
match-columns | The match columns step renders |
review-entries | The review entries step renders |
complete | After complete() is called inside onResults |
Basic syntax
<DataImporter
onStepChange={(step) => {
// update URL or send analytics event
}}
/>