Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add withPathParameters #243

Open
1 task done
Thy3634 opened this issue May 22, 2024 · 1 comment
Open
1 task done

Add withPathParameters #243

Thy3634 opened this issue May 22, 2024 · 1 comment

Comments

@Thy3634
Copy link

Thy3634 commented May 22, 2024

Describe the feature

withPathParameters('/api/users/{userId}', { userId: 'abc' })
// '/api/users/abc'

mustache mode:

withPathParameters('/api/users/{{userId}}', { userId: 'abc' }, { interpolate = /{{([\s\S]+?)}}/g })
// '/api/users/abc'

Additional information

  • Would you be willing to help implement this feature?
@hello-netsocks
Copy link

We think it would be better to accept a more standarized url param's format.

Instead of this

withPathParameters('/api/users/{userId}', { userId: 'abc' })
// '/api/users/abc'

Use this:

withPathParameters('/api/users/:userId', { userId: 'abc' })
// '/api/users/abc'

We need this feature btw.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants