Skip to main content
Version: 11.14.0

Application

The ApplicationStore manages application-level flags (ready state, extracts) used by the Mint framework. It can be extended to add custom application state.

info

This store provides basic features you can easily extend to create your own application store.

Methods

update()

Updates the application state with the provided partial state.

update(state: Partial<ApplicationState>): void
NameTypeRequiredDescription
statePartial<ApplicationState>Partial state object with properties to update.

updateReadyState()

Sets the ready flag on the application store.

updateReadyState(value?: boolean): void
NameTypeRequiredDescription
valuebooleanThe ready state to set. Default: true.

updateExtracts()

Stores extract data for a given document ID.

updateExtracts(id: string, extracts: Extract[]): void
NameTypeRequiredDescription
idstringThe document ID.
extractsExtract[]The extracts to store for that document.

getExtracts()

Retrieves stored extracts for a given document ID.

getExtracts(id: string): Extract[]
NameTypeRequiredDescription
idstringThe document ID.

Returns Extract[] — the extracts for that document.

Computed values

extractsCount

Returns number — the total number of stored extracts.