fix: 解决 Vercel 刷新 404

This commit is contained in:
imsyy
2023-06-14 11:44:55 +08:00
parent 261997a627
commit 17bb9f13b8
2 changed files with 6 additions and 1 deletions

View File

@@ -415,10 +415,12 @@ const useMusicDataStore = defineStore("musicData", {
},
// 添加歌曲至播放列表
addSongToPlaylists(value, play = true) {
// 停止当前播放
if (typeof $player !== "undefined") soundStop($player);
// 判断与上一次播放歌曲是否一致
const index = this.persistData.playlists.findIndex(
(o) => o.id === value.id
);
// 判断与上一次播放歌曲是否一致
try {
if (
value.id !==

3
vercel.json Normal file
View File

@@ -0,0 +1,3 @@
{
"rewrites": [{ "source": "/:path*", "destination": "/index.html" }]
}