mirror of
https://github.com/ArthurDanjou/arthome.git
synced 2026-01-14 20:19:26 +01:00
Add icons to search query
This commit is contained in:
@@ -1,11 +1,12 @@
|
||||
import { IconsCollection } from '~~/types/types'
|
||||
|
||||
export default defineEventHandler(async (event) => {
|
||||
const collections = ['ph', 'heroicons']
|
||||
const { query } = getQuery(event)
|
||||
|
||||
const response = await $fetch('https://api.iconify.design/search', {
|
||||
params: {
|
||||
query,
|
||||
prefixes: collections.join(','),
|
||||
prefixes: IconsCollection.join(','),
|
||||
},
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user