import { ComputedRef, Ref, UnwrapRef } from 'vue-demi';
export type MaybeRef<T> = T | Ref<T>;
export type MaybeReactive<T> = T | UnwrapRef<T>;
export type IQueryParams = Record<string, null | undefined | string | number | string[] | (string | number)[] | Ref<any> | UnwrapRef<any>>;
export type IPathVariables = Record<string, string | number | Ref<any>>;
export interface IUrlOptions {
    path?: MaybeRef<string | number>;
    pathVariables?: MaybeReactive<IPathVariables>;
    queryParams?: MaybeReactive<IQueryParams>;
    hash?: MaybeRef<string | number>;
    arraySerializer?: (array: unknown[]) => string;
}
export interface IBuilderResult {
    path: Ref<string>;
    pathVariables: UnwrapRef<IPathVariables>;
    queryParams: UnwrapRef<IQueryParams>;
    hash: Ref<string | number>;
    arraySerializer: (array: unknown[]) => string;
    url: ComputedRef<string>;
    setUrl: (url: ComputedRef<string>) => void;
}
export declare class BuilderResult implements IBuilderResult {
    path: Ref<string>;
    pathVariables: UnwrapRef<IPathVariables>;
    queryParams: UnwrapRef<IQueryParams>;
    hash: Ref<string>;
    arraySerializer: (array: unknown[]) => string;
    url: ComputedRef<string>;
    constructor(path: MaybeRef<string>, pathVariables: MaybeReactive<IPathVariables>, queryParams: MaybeReactive<IQueryParams>, hash: MaybeRef<string>, arraySerializer: (array: unknown[]) => string);
    setUrl(url: ComputedRef<string>): void;
}
export declare class UrlBuilder {
    baseUrl: string;
    private defaultSerializer;
    constructor(baseUrl?: string | null | undefined);
    buildHash(url: string, hash: string | number): string;
    buildPathVariables(url: string, pathVariables: IPathVariables): string;
    buildQueryParams(url: string, queryParams: IQueryParams, arraySerializer?: (array: unknown[]) => string): string;
}
declare const useUrl: (options: IUrlOptions | any, baseUrl?: string) => IBuilderResult;
declare const createUseUrlInstance: () => (options: IUrlOptions | any, baseUrl?: string) => IBuilderResult;
export { useUrl, createUseUrlInstance };
