aboutsummaryrefslogtreecommitdiff
path: root/src-vue
diff options
context:
space:
mode:
authorAlystrasz <contact@remyraes.com>2022-10-04 08:05:53 +0200
committerAlystrasz <contact@remyraes.com>2022-10-04 08:05:53 +0200
commitc284e9aafc369784fa58cd0dc6a536c4bf2e1a84 (patch)
tree6ed3e6a1fba9d15e444e6295bc6851b1308f79f6 /src-vue
parentba53e308a0908d0852e23d86efc66acf837485e4 (diff)
downloadFlightCore-c284e9aafc369784fa58cd0dc6a536c4bf2e1a84.tar.gz
FlightCore-c284e9aafc369784fa58cd0dc6a536c4bf2e1a84.zip
refactor: rename store type
Diffstat (limited to 'src-vue')
-rw-r--r--src-vue/src/plugins/store.ts10
-rw-r--r--src-vue/src/vuex-shim.d.ts2
2 files changed, 6 insertions, 6 deletions
diff --git a/src-vue/src/plugins/store.ts b/src-vue/src/plugins/store.ts
index 7f649a51..9d1bd89f 100644
--- a/src-vue/src/plugins/store.ts
+++ b/src-vue/src/plugins/store.ts
@@ -9,7 +9,7 @@ import { ElNotification } from 'element-plus';
import { NorthstarState } from '../utils/NorthstarState';
-export type Store = {
+export interface FlightCoreStore {
current_tab: Tabs,
developer_mode: boolean,
game_path: string,
@@ -23,13 +23,13 @@ export type Store = {
origin_is_running: boolean
}
-export const store = createStore({
- state () {
+export const store = createStore<FlightCoreStore>({
+ state (): FlightCoreStore {
return {
current_tab: Tabs.PLAY,
developer_mode: false,
- game_path: undefined,
- install_type: undefined,
+ game_path: undefined as unknown as string,
+ install_type: undefined as unknown as InstallType,
installed_northstar_version: "",
northstar_state: NorthstarState.GAME_NOT_FOUND,
diff --git a/src-vue/src/vuex-shim.d.ts b/src-vue/src/vuex-shim.d.ts
index 1429115b..40438a97 100644
--- a/src-vue/src/vuex-shim.d.ts
+++ b/src-vue/src/vuex-shim.d.ts
@@ -3,6 +3,6 @@ import { Store } from 'vuex'
declare module '@vue/runtime-core' {
interface ComponentCustomProperties {
- $store: Store<State>
+ $store: Store<FlightCoreStore>
}
}