Currently the types for the routes do not restrict the "?" property to be a function. This should be the case.
export interface Routes<T = any> {
[k: string]: Routes<T> | Resolve<T>;
}
I already tried it with a conditional type and with intersection types, but I didn't get it working yet.
PR welcome.