bpms_site/.svn/pristine/48/488d0a46808c25b87a26a5a7c738dbd08a53ed81.svn-base
2025-11-02 16:38:49 +03:30

15 lines
452 B
Plaintext

import matchBundle from "./match-bundle";
// matches app/:path*.js
const APP_ROUTE_NAME_REGEX = /^app[/\\](.*)$/;
export default function getAppRouteFromEntrypoint(entryFile) {
const pagePath = matchBundle(APP_ROUTE_NAME_REGEX, entryFile);
if (typeof pagePath === "string" && !pagePath) {
return "/";
}
if (!pagePath) {
return null;
}
return pagePath;
}
//# sourceMappingURL=get-app-route-from-entrypoint.js.map