feat: search

This commit is contained in:
Philipinho
2024-01-30 00:14:21 +01:00
parent e0e5f7c43d
commit a0ec2f30ca
22 changed files with 509 additions and 161 deletions

View File

@ -0,0 +1,7 @@
import api from '@/lib/api-client';
import { IPageSearch } from '@/features/search/types/search.types';
export async function searchPage(query: string): Promise<IPageSearch[]> {
const req = await api.post<IPageSearch[]>('/search', { query });
return req.data as any;
}