initial Commit

This commit is contained in:
Niko Feith 2023-02-15 16:13:40 +01:00
parent 695c104f69
commit 0b0dbc6c1f
4 changed files with 43 additions and 0 deletions

View File

@ -11,6 +11,7 @@
"lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore" "lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore"
}, },
"dependencies": { "dependencies": {
"chart.js": "^4.2.1",
"pinia": "^2.0.30", "pinia": "^2.0.30",
"roslib": "^1.3.0", "roslib": "^1.3.0",
"vue": "^3.2.45", "vue": "^3.2.45",

View File

@ -0,0 +1,20 @@
<template>
<div>
<canvas id="reward-chart"/>
</div>
</template>
<script setup>
import {
onMounted,
watch,
} from "vue";
import { Chart } from 'chart.js/auto';
</script>
<style scoped>
</style>

View File

@ -0,0 +1,22 @@
import { defineStore } from "pinia";
export const useMCStore = defineStore('MountainCarStore', {
state: () => {
return {
play: false,
rgbArray: Array,
}
},
getters: {
getPlay: (state) => state.play,
getRgbArray: (state) => state.rgbarray,
},
actions: {
setPlay() {
this.play = !this.play;
},
setRgbArray(value) {
this.rgbArray = value;
},
}
})