SpoonX / aurelia-api

A simple convenience wrapper around aurelia-fetch-client
http://aurelia-api.spoonx.org
MIT License
72 stars 21 forks source link

Make buildQueryString second parameter 'traditional' configurable #187

Closed MayGo closed 7 years ago

MayGo commented 7 years ago

Problem:

let params={mylist:["one", "two", "three"]};
this.apiEndpoint.find('something', params);

Makes query ?mylist[]=one&mylist[]=two&mylist[]=three.

but is needed query ?mylist=one&mylist=two&mylist=three.

aurelia-api uses aurelia-path function buildQueryString(params, traditional), that makes query the way it is needed when traditional = true.

Needed feature:

Provide a way to configure buildQueryString-s traditional parameter.

RWOverdijk commented 7 years ago

@MayGo Nice. We can add this to the endpoint configuration. Would you like to submit a PR?

MayGo commented 7 years ago

yes, i will try.

MayGo commented 7 years ago

duplicate #175 not released yet

RWOverdijk commented 7 years ago

@MayGo This is part of another issue we're working on. Publishing has to hold until we fix the babel issue. Shouldn't be too long now :)