Skip to content

Commit

Permalink
fix: 🐛 playground fetch collection now works
Browse files Browse the repository at this point in the history
Moved fetchCollection function outside of fetch articles
  • Loading branch information
craigharman committed Jul 20, 2022
1 parent 997b545 commit 2c4f260
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions playground/app.vue
Original file line number Diff line number Diff line change
Expand Up @@ -99,14 +99,14 @@ const fetchArticles = async () => {
router.push('/d')
} catch (e) { }
}
const fetchCollections = async () => {
try {
const collections = await getCollections()
console.log(collections)
const fetchCollections = async () => {
try {
const collections = await getCollections()
console.log(collections)
router.push('/d')
} catch (e) { }
}
router.push('/d')
} catch (e) { }
}
</script>

0 comments on commit 2c4f260

Please sign in to comment.