wip: refactor(client): migrate paging components to composition api
This commit is contained in:
parent
7271fbb092
commit
2900f998b1
3 changed files with 58 additions and 84 deletions
|
|
@ -65,26 +65,14 @@
|
|||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import { defineComponent } from 'vue';
|
||||
<script lang="ts" setup>
|
||||
import { computed } from 'vue';
|
||||
import MkButton from '@/components/ui/button.vue';
|
||||
import { defaultStore } from '@/store';
|
||||
|
||||
export default defineComponent({
|
||||
components: {
|
||||
MkButton,
|
||||
},
|
||||
|
||||
data() {
|
||||
return {
|
||||
}
|
||||
},
|
||||
|
||||
computed: {
|
||||
tutorial: {
|
||||
get() { return this.$store.reactiveState.tutorial.value || 0; },
|
||||
set(value) { this.$store.set('tutorial', value); }
|
||||
},
|
||||
},
|
||||
const tutorial = computed({
|
||||
get() { return defaultStore.reactiveState.tutorial.value || 0; },
|
||||
set(value) { defaultStore.set('tutorial', value); }
|
||||
});
|
||||
</script>
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue