storeModelConfig
Overview
A store for model configuration.
Signature
storeModelConfig(pinia, hot)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| pinia | Pinia | no | Pinia instance to retrieve the store |
| hot | StoreGeneric | no | dev only hot module replacement |
Returns
Store
Properties
$id
Id of the store. Used by map helpers.
Type: "modelConfig"
Source: node_modules/.pnpm/pinia@3.0.4_typescript@5.9.3_vue@3.5.43_typescript@5.9.3_/node_modules/pinia/dist/pinia.d.ts:654
authScopeGeneration
Incremented by clearAuthScoped. Builds capture it before awaiting and discard their result if it changed while the build was in flight.
Type: number
Source: client/lib/stores/storeModelConfig.js:619
builtConfigs
Finished configs that getConfig built from model info and both kinds of overrides. The key is the app, model, and view dot name, or the app and model dot name when no view was given.
Type: object
Source: client/lib/stores/storeModelConfig.js:603
genericConfigs
View-independent config overrides that setConfig stores, keyed by app and model dot name.
Type: object
Source: client/lib/stores/storeModelConfig.js:589
initialized
The in-flight getConfig builds. The key is the app, model, and view dot name. When no view was given, the key is the app and model dot name. A build that succeeds or is cancelled removes its entry. A build that fails keeps its rejected promise here until setConfig for the model or clearAuthScoped removes it. Each promise has a cancel method.
Type: object
Source: client/lib/stores/storeModelConfig.js:612
specificConfigs
View-specific config overrides that setConfig stores, keyed by app, model, and view dot name. A read view is stored under retrieve.
Type: object
Source: client/lib/stores/storeModelConfig.js:596
Methods
- clearAuthScoped - Drops the built configs, because they are derived from permission-filtered model info.
- getConfig - Builds the merged config for a model, or for one of its views, and caches it.
- setConfig - Stores generic and view-specific model config overrides.
Source
client/lib/stores/storeModelConfig.js:582