👖
Pants - Page 1
Showing page 1 of 5
Path: /marketplace/clothing/pants/1
3
Path Depth
267
Total Items
1
Current Page
12
Items Shown
Nested Marketplace Route
File:
/marketplace/[...path].astro
Handles:
/marketplace/category/subcategory/page
Current path:
["clothing", "pants", "1"]
Parsed as:
Category: "clothing", Subcategory: "pants", Page: "1"
👖
Samsung pant 1
$230
★ 3.8
493 reviews
👖
Sony pant 2
$808
★ 3.7
461 reviews
👖
LG pant 3
$165
★ 3.8
499 reviews
👖
Dell pant 4
$648
★ 3.6
308 reviews
👖
HP pant 5
$57
★ 3.8
471 reviews
👖
Nike pant 6
$981
★ 3.9
184 reviews
👖
Adidas pant 7
$76
★ 4.6
345 reviews
👖
Apple pant 8
$701
★ 4.4
247 reviews
👖
Samsung pant 9
$431
★ 3.8
359 reviews
👖
Sony pant 10
$236
★ 3.6
153 reviews
👖
LG pant 11
$192
★ 4.4
335 reviews
👖
Dell pant 12
$433
★ 4.0
281 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>