import { ref, onMounted } from 'vue'
export function useSearchArticles() {
const articles = ref([])
const searchParameters = ref([])
onMounted(() => {
this.articles = ArticlesAPI.loadArticles()
})
const searchArticles = (id) => {
return articles.filter(() => {
// some search code
})
}
return {
articles,
searchParameters,
searchArticles,
}
}