Skip to content

Commit 3cd3d57

Browse files
add a description to the TourRunner component
which makes it clear that this is not meant to be reused in any other component than `App.vue` where it is mounted based on `tourStore.currentTour.id`.
1 parent 15361de commit 3cd3d57

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

client/src/components/Tour/TourRunner.vue

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,14 @@
11
<script setup lang="ts">
2+
/**
3+
* Component that runs a tour with the given ID.
4+
* It handles waiting for elements to appear and performing any pre-step actions like clicking or text insertion.
5+
*
6+
* Note: This is not meant to be reused in other components, it is only meant to be mounted in `App.vue`.
7+
* There, we check the `tourStore.currentTour.id` and mount this component if it is set.
8+
* Therefore, to start a tour, just set the `tourStore.currentTour` to the desired tour ID,
9+
* and `App.vue` will mount this component automatically.
10+
*/
11+
212
import { storeToRefs } from "pinia";
313
import { ref } from "vue";
414

0 commit comments

Comments
 (0)