@uni-helper/vite-plugin-uni-pages 0.2.19 → 0.2.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -487,7 +487,7 @@ class PageContext {
487
487
  const subPackages = this.pagesGlobConfig?.subPackages || [];
488
488
  for (const [dir, pages] of Object.entries(this.subPagesPath)) {
489
489
  const basePath = slash(path__default.join(this.options.root, this.options.outDir));
490
- const root = slash(path__default.relative(basePath, dir));
490
+ const root = slash(path__default.relative(basePath, path__default.join(this.options.root, dir)));
491
491
  const globPackage = subPackages?.find((v) => v.root === root);
492
492
  subPageMaps[root] = await this.parsePages(pages, "sub", globPackage?.pages);
493
493
  subPageMaps[root] = subPageMaps[root].map((page) => ({ ...page, path: slash(path__default.relative(root, page.path)) }));
package/dist/index.mjs CHANGED
@@ -472,7 +472,7 @@ class PageContext {
472
472
  const subPackages = this.pagesGlobConfig?.subPackages || [];
473
473
  for (const [dir, pages] of Object.entries(this.subPagesPath)) {
474
474
  const basePath = slash(path.join(this.options.root, this.options.outDir));
475
- const root = slash(path.relative(basePath, dir));
475
+ const root = slash(path.relative(basePath, path.join(this.options.root, dir)));
476
476
  const globPackage = subPackages?.find((v) => v.root === root);
477
477
  subPageMaps[root] = await this.parsePages(pages, "sub", globPackage?.pages);
478
478
  subPageMaps[root] = subPageMaps[root].map((page) => ({ ...page, path: slash(path.relative(root, page.path)) }));
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@uni-helper/vite-plugin-uni-pages",
3
3
  "type": "module",
4
- "version": "0.2.19",
4
+ "version": "0.2.20",
5
5
  "description": "File system based routing for uni-app applications using Vite",
6
6
  "author": "KeJun",
7
7
  "license": "MIT",