watch
This commit is contained in:
@@ -29,7 +29,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { onMounted } from 'vue'
|
import { onMounted, watch, computed } from 'vue'
|
||||||
import { useRoute } from 'vue-router'
|
import { useRoute } from 'vue-router'
|
||||||
import { supabaseStore } from '../stores/supabaseStore'
|
import { supabaseStore } from '../stores/supabaseStore'
|
||||||
import useSupabase from '../boot/supabase'
|
import useSupabase from '../boot/supabase'
|
||||||
@@ -38,6 +38,12 @@ const { supabase } = useSupabase()
|
|||||||
const store = supabaseStore()
|
const store = supabaseStore()
|
||||||
const route = useRoute()
|
const route = useRoute()
|
||||||
|
|
||||||
|
watch((computed(() => store.items)), (newItems, oldItems) => {
|
||||||
|
console.log(newItems, oldItems)
|
||||||
|
|
||||||
|
}, { deep: true })
|
||||||
|
|
||||||
|
|
||||||
const onLoad = (index, done) => {
|
const onLoad = (index, done) => {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
store.listas.push()
|
store.listas.push()
|
||||||
|
|||||||
Reference in New Issue
Block a user