Closed t170815518 closed 1 year ago
Your SFC structure should look like this:
<template>
// your template stuff
<CalendarHeatmap></CalendarHeatmap>
</template>
<script>
import { CalendarHeatmap } from 'vue3-calendar-heatmap'
export default {
components: {
CalendarHeatmap
},
// ...
}
</script>
May that's your error. Further more you need to add required informations:
A fully working erxample can be found here: https://github.com/razorness/vue3-calendar-heatmap/blob/master/docs/.vuepress/components/Demo.vue
And here: https://github.com/razorness/vue3-calendar-heatmap/blob/master/src/App.vue
You can clone this repository and play with the dev
environment which runs App.vue to get a better understanding:
git clone https://github.com/razorness/vue3-calendar-heatmap.git
cd vue3-calendar-heatmap
yarn
yarn dev
Thank you very much for the help, @razorness, I missed the required parameters like values and endDate as you pointed out.
After adding them, the heatmap can be displayed properly. :)
I am pretty new to Vue, and when I followed the instructions to import the component locally:
I got the error
Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'map')
?Thank you for the help in advance :)