/** * functions and constants which helps to build * nextjs or react router dom navigation operations * for an entity. */ export const GeoCityNavigationTools = { edit(uniqueId: string, locale?: string) { return `${locale ? "/" + locale : ""}/geo-city/edit/${uniqueId}`; }, create(locale?: string) { return `${locale ? "/" + locale : ""}/geo-city/new`; }, single(uniqueId: string, locale?: string) { return `${locale ? "/" + locale : ""}/geo-city/${uniqueId}`; }, query(params: any = {}, locale?: string) { return `${locale ? "/" + locale : ""}/geo-cities`; }, /** * Use R series while building router in CRA or nextjs, or react navigation for react Native * Might be useful in Angular as well. **/ Redit: "geo-city/edit/:uniqueId", Rcreate: "geo-city/new", Rsingle: "geo-city/:uniqueId", Rquery: "geo-cities", };