Slide 17
Slide 17 text
API routes
@marcelltech
/test.ts
/api/test
Put your
f
iles under src/server/routes
/api/**
/[…]ts
POST /api/test
/test.post.ts Works with .get, .post, .put, .delete
Catch-all routes
/api/products/:productId
/products/[productId].ts
Dynamic routes
Source: https://analogjs.org/docs/features/api/overview