@refinedev/core
Version:
refine is a React-based framework for building internal tools, rapidly. It ships with Ant Design System, an enterprise-level UI toolkit.
15 lines • 628 B
text/typescript
import type { IResourceItem } from "../../../contexts/resource/types";
import type { Action } from "../../../contexts/router/types";
/**
* Match the resource from the route
* - It will calculate all possible routes for resources and their actions
* - It will check if the route matches any of the possible routes
* - It will return the most eligible resource and action
*/
export declare const matchResourceFromRoute: (route: string, resources: IResourceItem[]) => {
found: boolean;
resource?: IResourceItem;
action?: Action;
matchedRoute?: string;
};
//# sourceMappingURL=match-resource-from-route.d.ts.map