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

API docs are missing for HttpParamsOptions #20276

Closed
dinvlad opened this issue Nov 8, 2017 · 18 comments
Closed

API docs are missing for HttpParamsOptions #20276

dinvlad opened this issue Nov 8, 2017 · 18 comments
Assignees
Labels
area: common/http feature Issue that requests a new feature freq3: high P4 A relatively minor issue that is not relevant to core functions state: blocked state: has PR
Milestone

Comments

@dinvlad
Copy link

dinvlad commented Nov 8, 2017

I'm submitting a...


[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report  
[ ] Feature request
[x] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question

Current behavior

HttpParams is documented on Angular.io, however its constructor takes HttpParamsOptions that doesn't link to a doc.

Expected behavior

We could infer the shape of HttpParamsOptions from the source code, but it would be nice to describe, link to and search for it on the API portal.

Minimal reproduction of the problem with instructions

What is the motivation / use case for changing the behavior?

Environment

Angular 5.0.0

Others:

https://angular.io/api/common/http/

@geowrgetudor
Copy link

I was looking for this yesterday :)

gkalpak added a commit to gkalpak/angular that referenced this issue Nov 10, 2017
gkalpak added a commit to gkalpak/angular that referenced this issue Nov 11, 2017
gkalpak added a commit to gkalpak/angular that referenced this issue Nov 13, 2017
gkalpak added a commit to gkalpak/angular that referenced this issue Nov 13, 2017
@eladcandroid
Copy link

Any news?

@gkalpak
Copy link
Member

gkalpak commented Dec 11, 2017

@alxhub, why label it as comp: http instead of comp: common/http?
See #20332.

@geowrgetudor
Copy link

geowrgetudor commented Dec 11, 2017

Just note that HttpParams doesn't add up to the previous params just like HttpSearchParams used to do.

`let body = new HttpParams();
body.set('some_var', 'value');
body.set('another_var', 'value');

console.log(body.toString()); // will return null

body = body.set('some_var', 'value');
body = body.set('another_var', 'value');

console.log(body.toString()); //will return the params`

@ngbot ngbot bot added this to the Backlog milestone Jan 23, 2018
gkalpak added a commit to gkalpak/angular that referenced this issue Jan 25, 2018
gkalpak added a commit to gkalpak/angular that referenced this issue Jan 25, 2018
@mhevery
Copy link
Contributor

mhevery commented Feb 5, 2018

fixed by #20332

@mhevery mhevery closed this as completed Feb 5, 2018
gkalpak added a commit to gkalpak/angular that referenced this issue Feb 6, 2018
mhevery pushed a commit that referenced this issue Feb 8, 2018
mhevery pushed a commit that referenced this issue Feb 8, 2018
jbogarthyde pushed a commit to jbogarthyde/angular that referenced this issue Feb 23, 2018
@jenniferfell
Copy link
Contributor

@jbogarthyde To keep an eye on. :-)

@MattiJarvinen
Copy link

How's this progressing?

@pickfire
Copy link
Contributor

HttpParamsOptions should not be referenced by public API.

@gkalpak I believe that HttpParamsOptions should be referenced by public API for others to be able to override the encoder as it does not encode some characters such as + and =, See #26979 and #18261.

@trotyl
Copy link
Contributor

trotyl commented Jan 14, 2019

@pickfire It means HttpParamsOptions interface is going to be inlined, so that HttpParamsOptions name doesn't exist anymore, which becoming part of the constructor type directly.

gkalpak added a commit to gkalpak/angular that referenced this issue Jan 14, 2019
@pickfire
Copy link
Contributor

@trotyl Nice, I see what that means now. It definitely will be better in this case.

gkalpak added a commit to gkalpak/angular that referenced this issue Jan 16, 2019
gkalpak added a commit to gkalpak/angular that referenced this issue Apr 3, 2019
gkalpak added a commit to gkalpak/angular that referenced this issue Jul 25, 2019
rwlogel pushed a commit to rwlogel/angular that referenced this issue Mar 3, 2020
rwlogel pushed a commit to rwlogel/angular that referenced this issue Mar 3, 2020
rwlogel pushed a commit to rwlogel/angular that referenced this issue Mar 16, 2020
@jeserkin
Copy link

jeserkin commented May 12, 2020

How are things progressing on this issue?

I noticed it was created in 2017 and till now it still produces same result. By result I mean, that https://angular.io/api/common/http/HttpParams references HttpParamsOptions type, but this type has no reference and therefore doesn't tell developer/user, what it provides/consists of.

To find answers one needs to go https://github.com/angular/angular/blob/master/packages/common/http/src/params.ts#L113, but it is painful, when there are docs.

rwlogel pushed a commit to rwlogel/angular that referenced this issue Jul 28, 2020
The `HttpParamsOptions` was not documented or included in the public API even
though it is a constructor argument of `HttpParams` which is a part of the
public API. This commit adds the `HttpParamsOptions` into the exports, thus
making it a part of the public API.

Resolves angular#20276
@rooby
Copy link

rooby commented Aug 3, 2020

This documentation is made more important by the fact that the default encoder doesn't work and you need to know how to override with a custom one. See #11058

@jelbourn jelbourn added P4 A relatively minor issue that is not relevant to core functions and removed severity2: inconvenient labels Oct 1, 2020
atscott pushed a commit to rwlogel/angular that referenced this issue Nov 12, 2020
The `HttpParamsOptions` was not documented or included in the public API even
though it is a constructor argument of `HttpParams` which is a part of the
public API. This commit adds the `HttpParamsOptions` into the exports, thus
making it a part of the public API.

Resolves angular#20276
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Dec 19, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area: common/http feature Issue that requests a new feature freq3: high P4 A relatively minor issue that is not relevant to core functions state: blocked state: has PR
Projects
None yet
Development

Successfully merging a pull request may close this issue.