Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
qiujie8092916 committed Oct 17, 2023
1 parent 879d66c commit c7382a9
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packages/core/src/Route/Route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ class Route {
!opts.isConventional &&
typeof route.component === 'string' &&
!route.component.startsWith('@/') &&
!route.component.startsWith('@@/') &&
!path.isAbsolute(route.component)
) {
route.component = winPath(join(opts.root, route.component));
Expand All @@ -116,7 +117,11 @@ class Route {
// resolve wrappers path
if (route.wrappers) {
route.wrappers = route.wrappers.map((wrapper) => {
if (wrapper.startsWith('@/') || path.isAbsolute(wrapper)) {
if (
wrapper.startsWith('@/') ||
wrapper.startsWith('@@/') ||
path.isAbsolute(wrapper)
) {
return wrapper;
} else {
return winPath(join(opts.root, wrapper));
Expand Down

0 comments on commit c7382a9

Please sign in to comment.