@pinia/root / pinia / SetupStoreDefinition
SetupStoreDefinition()<Id, SS>
Return type of defineStore() with a setup function.
Idis a string literal of the store's nameSSis the return type of the setup function
See
Extends
StoreDefinition<Id,_ExtractStateFromSetupStore<SS>,_ExtractGettersFromSetupStore<SS>,_ExtractActionsFromSetupStore<SS>>
Type Parameters
Id
Id extends string
SS
SS
ts
SetupStoreDefinition(pinia?, hot?): Store<Id, _ExtractStateFromSetupStore<SS>, _ExtractGettersFromSetupStore<SS>, _ExtractActionsFromSetupStore<SS>>;Returns a store, creates it if necessary.
Parameters
pinia?
Pinia instance to retrieve the store
Pinia | null
hot?
dev only hot module replacement
Returns
Store<Id, _ExtractStateFromSetupStore<SS>, _ExtractGettersFromSetupStore<SS>, _ExtractActionsFromSetupStore<SS>>
Properties
$id
ts
$id: Id;Id of the store. Used by map helpers.

