10 lines
253 B
TypeScript
10 lines
253 B
TypeScript
|
import type { LocationQueryValue } from 'vue-router';
|
||
|
|
||
|
export function queryToString(item?: null | LocationQueryValue | LocationQueryValue[]) {
|
||
|
if (item === null)
|
||
|
return "";
|
||
|
if (item instanceof Array)
|
||
|
return queryToString(item[0])
|
||
|
return item;
|
||
|
}
|