Poprawki optymalizacyjne; dodanie ostrzeżeń

This commit is contained in:
2021-11-13 15:27:26 +01:00
parent 8e9da4c498
commit 28c9813133
8 changed files with 414 additions and 253 deletions
+9 -17
View File
@@ -1,24 +1,16 @@
import { createApp } from "vue";
import App from "./App.vue";
import { ICargo, ICarWagon, ILocomotive, IStock, IStore } from "./types";
import { reactive } from "@vue/reactivity";
const Store: IStore = reactive({
chosenCar: null as ICarWagon | null,
chosenLoco: null as ILocomotive | null,
chosenCargo: null as ICargo | null,
showSupporter: false,
imageLoading: false,
chosenLocoPower: "loco-e",
chosenCarUseType: "car-passenger",
stockList: [] as IStock[],
cargoOptions: [] as any[][],
})
import { Store, locoDataList, carDataList, totalLength, totalMass, maxAllowedSpeed, maxStockSpeed, isTrainPassenger, warnings } from "./store";
createApp(App)
.provide('Store', Store)
.provide('locoDataList', locoDataList)
.provide('carDataList', carDataList)
.provide('totalMass', totalMass)
.provide('totalLength', totalLength)
.provide('maxStockSpeed', maxStockSpeed)
.provide('maxAllowedSpeed', maxAllowedSpeed)
.provide('isTrainPassenger', isTrainPassenger)
.provide('warnings', warnings)
.mount("#app");