@tanstack/virtual-file-routes 1.64.0 → 1.81.9

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.
@@ -1 +1 @@
1
- {"version":3,"file":"api.cjs","sources":["../../src/api.ts"],"sourcesContent":["import type {\n IndexRoute,\n LayoutRoute,\n PhysicalSubtree,\n Route,\n VirtualRootRoute,\n VirtualRouteNode,\n} from './types'\n\nexport function rootRoute(\n file: string,\n children?: Array<VirtualRouteNode>,\n): VirtualRootRoute {\n return {\n type: 'root',\n file,\n children,\n }\n}\n\nexport function index(file: string): IndexRoute {\n return {\n type: 'index',\n file,\n }\n}\n\nexport function layout(\n file: string,\n children: Array<VirtualRouteNode>,\n): LayoutRoute\nexport function layout(\n id: string,\n file: string,\n children: Array<VirtualRouteNode>,\n): LayoutRoute\n\nexport function layout(\n idOrFile: string,\n fileOrChildren: string | Array<VirtualRouteNode>,\n children?: Array<VirtualRouteNode>,\n): LayoutRoute {\n if (Array.isArray(fileOrChildren)) {\n return {\n type: 'layout',\n file: idOrFile,\n children: fileOrChildren,\n }\n } else {\n return {\n type: 'layout',\n id: idOrFile,\n file: fileOrChildren,\n children,\n }\n }\n}\n\nexport function route(path: string, children: Array<VirtualRouteNode>): Route\nexport function route(path: string, file: string): Route\nexport function route(\n path: string,\n file: string,\n children: Array<VirtualRouteNode>,\n): Route\nexport function route(\n path: string,\n fileOrChildren: string | Array<VirtualRouteNode>,\n children?: Array<VirtualRouteNode>,\n): Route {\n if (typeof fileOrChildren === 'string') {\n return {\n type: 'route',\n file: fileOrChildren,\n path,\n children,\n }\n }\n return {\n type: 'route',\n path,\n children: fileOrChildren,\n }\n}\n\nexport function physical(\n pathPrefix: string,\n directory: string,\n): PhysicalSubtree {\n return {\n type: 'physical',\n directory,\n pathPrefix,\n }\n}\n"],"names":[],"mappings":";;AASgB,SAAA,UACd,MACA,UACkB;AACX,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA;AAAA,EAAA;AAEJ;AAEO,SAAS,MAAM,MAA0B;AACvC,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,EAAA;AAEJ;AAYgB,SAAA,OACd,UACA,gBACA,UACa;AACT,MAAA,MAAM,QAAQ,cAAc,GAAG;AAC1B,WAAA;AAAA,MACL,MAAM;AAAA,MACN,MAAM;AAAA,MACN,UAAU;AAAA,IAAA;AAAA,EACZ,OACK;AACE,WAAA;AAAA,MACL,MAAM;AAAA,MACN,IAAI;AAAA,MACJ,MAAM;AAAA,MACN;AAAA,IAAA;AAAA,EAEJ;AACF;AASgB,SAAA,MACd,MACA,gBACA,UACO;AACH,MAAA,OAAO,mBAAmB,UAAU;AAC/B,WAAA;AAAA,MACL,MAAM;AAAA,MACN,MAAM;AAAA,MACN;AAAA,MACA;AAAA,IAAA;AAAA,EAEJ;AACO,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA,UAAU;AAAA,EAAA;AAEd;AAEgB,SAAA,SACd,YACA,WACiB;AACV,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA;AAAA,EAAA;AAEJ;;;;;;"}
1
+ {"version":3,"file":"api.cjs","sources":["../../src/api.ts"],"sourcesContent":["import type {\n IndexRoute,\n LayoutRoute,\n PhysicalSubtree,\n Route,\n VirtualRootRoute,\n VirtualRouteNode,\n} from './types'\n\nexport function rootRoute(\n file: string,\n children?: Array<VirtualRouteNode>,\n): VirtualRootRoute {\n return {\n type: 'root',\n file,\n children,\n }\n}\n\nexport function index(file: string): IndexRoute {\n return {\n type: 'index',\n file,\n }\n}\n\nexport function layout(\n file: string,\n children: Array<VirtualRouteNode>,\n): LayoutRoute\nexport function layout(\n id: string,\n file: string,\n children: Array<VirtualRouteNode>,\n): LayoutRoute\n\nexport function layout(\n idOrFile: string,\n fileOrChildren: string | Array<VirtualRouteNode>,\n children?: Array<VirtualRouteNode>,\n): LayoutRoute {\n if (Array.isArray(fileOrChildren)) {\n return {\n type: 'layout',\n file: idOrFile,\n children: fileOrChildren,\n }\n } else {\n return {\n type: 'layout',\n id: idOrFile,\n file: fileOrChildren,\n children,\n }\n }\n}\n\nexport function route(path: string, children: Array<VirtualRouteNode>): Route\nexport function route(path: string, file: string): Route\nexport function route(\n path: string,\n file: string,\n children: Array<VirtualRouteNode>,\n): Route\nexport function route(\n path: string,\n fileOrChildren: string | Array<VirtualRouteNode>,\n children?: Array<VirtualRouteNode>,\n): Route {\n if (typeof fileOrChildren === 'string') {\n return {\n type: 'route',\n file: fileOrChildren,\n path,\n children,\n }\n }\n return {\n type: 'route',\n path,\n children: fileOrChildren,\n }\n}\n\nexport function physical(\n pathPrefix: string,\n directory: string,\n): PhysicalSubtree {\n return {\n type: 'physical',\n directory,\n pathPrefix,\n }\n}\n"],"names":[],"mappings":";;AASgB,SAAA,UACd,MACA,UACkB;AACX,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA;AAAA,EACF;AACF;AAEO,SAAS,MAAM,MAA0B;AACvC,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,EACF;AACF;AAYgB,SAAA,OACd,UACA,gBACA,UACa;AACT,MAAA,MAAM,QAAQ,cAAc,GAAG;AAC1B,WAAA;AAAA,MACL,MAAM;AAAA,MACN,MAAM;AAAA,MACN,UAAU;AAAA,IACZ;AAAA,EAAA,OACK;AACE,WAAA;AAAA,MACL,MAAM;AAAA,MACN,IAAI;AAAA,MACJ,MAAM;AAAA,MACN;AAAA,IACF;AAAA,EAAA;AAEJ;AASgB,SAAA,MACd,MACA,gBACA,UACO;AACH,MAAA,OAAO,mBAAmB,UAAU;AAC/B,WAAA;AAAA,MACL,MAAM;AAAA,MACN,MAAM;AAAA,MACN;AAAA,MACA;AAAA,IACF;AAAA,EAAA;AAEK,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA,UAAU;AAAA,EACZ;AACF;AAEgB,SAAA,SACd,YACA,WACiB;AACV,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA;AAAA,EACF;AACF;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"api.js","sources":["../../src/api.ts"],"sourcesContent":["import type {\n IndexRoute,\n LayoutRoute,\n PhysicalSubtree,\n Route,\n VirtualRootRoute,\n VirtualRouteNode,\n} from './types'\n\nexport function rootRoute(\n file: string,\n children?: Array<VirtualRouteNode>,\n): VirtualRootRoute {\n return {\n type: 'root',\n file,\n children,\n }\n}\n\nexport function index(file: string): IndexRoute {\n return {\n type: 'index',\n file,\n }\n}\n\nexport function layout(\n file: string,\n children: Array<VirtualRouteNode>,\n): LayoutRoute\nexport function layout(\n id: string,\n file: string,\n children: Array<VirtualRouteNode>,\n): LayoutRoute\n\nexport function layout(\n idOrFile: string,\n fileOrChildren: string | Array<VirtualRouteNode>,\n children?: Array<VirtualRouteNode>,\n): LayoutRoute {\n if (Array.isArray(fileOrChildren)) {\n return {\n type: 'layout',\n file: idOrFile,\n children: fileOrChildren,\n }\n } else {\n return {\n type: 'layout',\n id: idOrFile,\n file: fileOrChildren,\n children,\n }\n }\n}\n\nexport function route(path: string, children: Array<VirtualRouteNode>): Route\nexport function route(path: string, file: string): Route\nexport function route(\n path: string,\n file: string,\n children: Array<VirtualRouteNode>,\n): Route\nexport function route(\n path: string,\n fileOrChildren: string | Array<VirtualRouteNode>,\n children?: Array<VirtualRouteNode>,\n): Route {\n if (typeof fileOrChildren === 'string') {\n return {\n type: 'route',\n file: fileOrChildren,\n path,\n children,\n }\n }\n return {\n type: 'route',\n path,\n children: fileOrChildren,\n }\n}\n\nexport function physical(\n pathPrefix: string,\n directory: string,\n): PhysicalSubtree {\n return {\n type: 'physical',\n directory,\n pathPrefix,\n }\n}\n"],"names":[],"mappings":"AASgB,SAAA,UACd,MACA,UACkB;AACX,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA;AAAA,EAAA;AAEJ;AAEO,SAAS,MAAM,MAA0B;AACvC,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,EAAA;AAEJ;AAYgB,SAAA,OACd,UACA,gBACA,UACa;AACT,MAAA,MAAM,QAAQ,cAAc,GAAG;AAC1B,WAAA;AAAA,MACL,MAAM;AAAA,MACN,MAAM;AAAA,MACN,UAAU;AAAA,IAAA;AAAA,EACZ,OACK;AACE,WAAA;AAAA,MACL,MAAM;AAAA,MACN,IAAI;AAAA,MACJ,MAAM;AAAA,MACN;AAAA,IAAA;AAAA,EAEJ;AACF;AASgB,SAAA,MACd,MACA,gBACA,UACO;AACH,MAAA,OAAO,mBAAmB,UAAU;AAC/B,WAAA;AAAA,MACL,MAAM;AAAA,MACN,MAAM;AAAA,MACN;AAAA,MACA;AAAA,IAAA;AAAA,EAEJ;AACO,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA,UAAU;AAAA,EAAA;AAEd;AAEgB,SAAA,SACd,YACA,WACiB;AACV,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA;AAAA,EAAA;AAEJ;"}
1
+ {"version":3,"file":"api.js","sources":["../../src/api.ts"],"sourcesContent":["import type {\n IndexRoute,\n LayoutRoute,\n PhysicalSubtree,\n Route,\n VirtualRootRoute,\n VirtualRouteNode,\n} from './types'\n\nexport function rootRoute(\n file: string,\n children?: Array<VirtualRouteNode>,\n): VirtualRootRoute {\n return {\n type: 'root',\n file,\n children,\n }\n}\n\nexport function index(file: string): IndexRoute {\n return {\n type: 'index',\n file,\n }\n}\n\nexport function layout(\n file: string,\n children: Array<VirtualRouteNode>,\n): LayoutRoute\nexport function layout(\n id: string,\n file: string,\n children: Array<VirtualRouteNode>,\n): LayoutRoute\n\nexport function layout(\n idOrFile: string,\n fileOrChildren: string | Array<VirtualRouteNode>,\n children?: Array<VirtualRouteNode>,\n): LayoutRoute {\n if (Array.isArray(fileOrChildren)) {\n return {\n type: 'layout',\n file: idOrFile,\n children: fileOrChildren,\n }\n } else {\n return {\n type: 'layout',\n id: idOrFile,\n file: fileOrChildren,\n children,\n }\n }\n}\n\nexport function route(path: string, children: Array<VirtualRouteNode>): Route\nexport function route(path: string, file: string): Route\nexport function route(\n path: string,\n file: string,\n children: Array<VirtualRouteNode>,\n): Route\nexport function route(\n path: string,\n fileOrChildren: string | Array<VirtualRouteNode>,\n children?: Array<VirtualRouteNode>,\n): Route {\n if (typeof fileOrChildren === 'string') {\n return {\n type: 'route',\n file: fileOrChildren,\n path,\n children,\n }\n }\n return {\n type: 'route',\n path,\n children: fileOrChildren,\n }\n}\n\nexport function physical(\n pathPrefix: string,\n directory: string,\n): PhysicalSubtree {\n return {\n type: 'physical',\n directory,\n pathPrefix,\n }\n}\n"],"names":[],"mappings":"AASgB,SAAA,UACd,MACA,UACkB;AACX,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA;AAAA,EACF;AACF;AAEO,SAAS,MAAM,MAA0B;AACvC,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,EACF;AACF;AAYgB,SAAA,OACd,UACA,gBACA,UACa;AACT,MAAA,MAAM,QAAQ,cAAc,GAAG;AAC1B,WAAA;AAAA,MACL,MAAM;AAAA,MACN,MAAM;AAAA,MACN,UAAU;AAAA,IACZ;AAAA,EAAA,OACK;AACE,WAAA;AAAA,MACL,MAAM;AAAA,MACN,IAAI;AAAA,MACJ,MAAM;AAAA,MACN;AAAA,IACF;AAAA,EAAA;AAEJ;AASgB,SAAA,MACd,MACA,gBACA,UACO;AACH,MAAA,OAAO,mBAAmB,UAAU;AAC/B,WAAA;AAAA,MACL,MAAM;AAAA,MACN,MAAM;AAAA,MACN;AAAA,MACA;AAAA,IACF;AAAA,EAAA;AAEK,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA,UAAU;AAAA,EACZ;AACF;AAEgB,SAAA,SACd,YACA,WACiB;AACV,SAAA;AAAA,IACL,MAAM;AAAA,IACN;AAAA,IACA;AAAA,EACF;AACF;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tanstack/virtual-file-routes",
3
- "version": "1.64.0",
3
+ "version": "1.81.9",
4
4
  "description": "Modern and scalable routing for React applications",
5
5
  "author": "Tanner Linsley",
6
6
  "license": "MIT",