👕
Shirts - Page 1
Showing page 1 of 5
Path: /marketplace/clothing/shirts/1
3
Path Depth
389
Total Items
1
Current Page
12
Items Shown
Nested Marketplace Route
File:
/marketplace/[...path].astro
Handles:
/marketplace/category/subcategory/page
Current path:
["clothing", "shirts", "1"]
Parsed as:
Category: "clothing", Subcategory: "shirts", Page: "1"
👕
Samsung shirt 1
$212
★ 3.8
253 reviews
👕
Sony shirt 2
$304
★ 3.8
402 reviews
👕
LG shirt 3
$800
★ 4.5
135 reviews
👕
Dell shirt 4
$121
★ 3.8
12 reviews
👕
HP shirt 5
$1025
★ 4.2
482 reviews
👕
Nike shirt 6
$849
★ 4.8
399 reviews
👕
Adidas shirt 7
$166
★ 4.2
25 reviews
👕
Apple shirt 8
$293
★ 3.7
256 reviews
👕
Samsung shirt 9
$56
★ 4.8
182 reviews
👕
Sony shirt 10
$764
★ 4.3
93 reviews
👕
LG shirt 11
$780
★ 3.8
331 reviews
👕
Dell shirt 12
$712
★ 4.2
347 reviews
Try These Marketplace Paths
/marketplace/electronics → Electronics category /marketplace/electronics/phones → Phone subcategory /marketplace/electronics/phones/2 → Page 2 of phones /marketplace/clothing/shoes/1 → Page 1 of shoes Nested Marketplace Implementation
---
// File: /marketplace/[...path].astro
export function getStaticPaths() {
// Pre-generate all possible marketplace paths
return [
{ params: { path: 'electronics' } },
{ params: { path: 'electronics/phones' } },
{ params: { path: 'electronics/phones/1' } },
{ params: { path: 'electronics/phones/2' } },
// ... more paths
];
}
const { path } = Astro.params;
const [category, subcategory, page] = path.split('/');
---
<h1>{category} → {subcategory} → Page {page}</h1>