feat: update front layout

This commit is contained in:
Maël Gangloff
2024-07-26 18:31:47 +02:00
parent a15c1b2c2f
commit 467d0efa1c
13 changed files with 272 additions and 177 deletions

View File

@@ -8,21 +8,8 @@ interface Tld {
}
export async function getTldList(params: object): Promise<Tld[]> {
let page = 1
let response = (await request<Tld[]>({
return (await request<Tld[]>({
url: 'tld',
params: {...params, page},
params,
})).data
const tldList: Tld[] = response;
while (response.length !== 0) {
page++
response = (await request<Tld[]>({
url: 'tld',
params: {...params, page},
})).data
tldList.push(...response)
}
return tldList
}