Great package you've created here! I've noticed an issue with the OpenAPI paths generated when more than one path parameter is supplied.
The package converts routes like /api/foo/bar/[qux]/route.ts to /api/foo/bar/{qux} just fine, but fails to convert paths when more than one path parameter exists.
For example, a path like /api/foo/bar/[qux]/quux/[corge]/route.ts gets converted to /api/foo/bar/{qux}/quux/[corge]. This ends up causing some pain when attempting to generate clients from the OpenAPI spec.
I think I found where the problem lies and will have a PR up shortly to fix this.
Hey there!
Great package you've created here! I've noticed an issue with the OpenAPI paths generated when more than one path parameter is supplied.
The package converts routes like
/api/foo/bar/[qux]/route.ts
to/api/foo/bar/{qux}
just fine, but fails to convert paths when more than one path parameter exists.For example, a path like
/api/foo/bar/[qux]/quux/[corge]/route.ts
gets converted to/api/foo/bar/{qux}/quux/[corge]
. This ends up causing some pain when attempting to generate clients from the OpenAPI spec.I think I found where the problem lies and will have a PR up shortly to fix this.