基本完成歌曲详情
This commit is contained in:
@@ -2,14 +2,17 @@
|
||||
import { ref, defineProps, onUnmounted, onDeactivated } from "vue";
|
||||
import { useRouter } from "vue-router";
|
||||
|
||||
const props = defineProps({ artists: Array, onLeave: Function });
|
||||
const router = useRouter()
|
||||
const props = defineProps({
|
||||
artists: Array,
|
||||
onLeave: Function,
|
||||
});
|
||||
const router = useRouter();
|
||||
// console.log(props.artists);
|
||||
|
||||
const click = (id) => {
|
||||
props.onLeave?.()
|
||||
router.push('/singer/' + id)
|
||||
}
|
||||
props.onLeave?.();
|
||||
router.push("/singer/" + id);
|
||||
};
|
||||
</script>
|
||||
<template>
|
||||
<template v-for="(ar, idx) of artists" key="idx">
|
||||
@@ -22,9 +25,7 @@ const click = (id) => {
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// export default {
|
||||
// props: ["artists"],
|
||||
// };
|
||||
|
||||
</script>
|
||||
|
||||
<style></style>
|
||||
|
||||
Reference in New Issue
Block a user