-
Notifications
You must be signed in to change notification settings - Fork 27.5k
Docs for $http interceptor - what is the config object? #12949
Comments
It is the same config object as documented in the "Usage" section of https://docs.angularjs.org/api/ng/service/$http In other words - the same config that is used to trigger the original $http call that is being intercepted. |
I don't understand. It says:
But it doesn't document what this object looks like. Below, it gives examples using the shortcut methods Edit: never mind, I see that it's documented below. So it's mentioned in the Usage section, but documented below. I still don't think it's clear that the config object mentioned is the Interceptors section refers to the same config object. Edit 2: sorry, I confused the wording. It is in fact documented in the Usage section like you said (I confused Usage with General Usage). But I still think my point remains about it not being clear that the config objects are the same. |
It's actually mentioned in the General Usage section (which might not be the best name), but document in the Usage section. |
The General Usage section itself doesn't show the config object very well, though, because it shows two examples with shortcuts. |
This makes it easier for beginners to find out what the config object looks like Closes angular#12949
I have a PR here: #12950 Technically, it's almost impossible to miss the Usage section when reading the docs, it's simply that there's so much in there, and a beginner doesn't really know that the usage section comes at the end .. |
The docs say that you have access to the config object, but don't say what the object looks like. It'd be helpful to know what the object looks like.
The text was updated successfully, but these errors were encountered: