They are both defined inside the
Component
that you are currently viewing, if you would just view their definition you will understand what they are. Also, Angular components have a
great amount of offline documentation, so if you would just hover over the type (
HttpClientModule
, for instance) you will be provided with a complete documentation and use case of the
Component
... Which I recommend that you do for the next
Component
or
Service
that you want to learn more about. :-)
Read
this[
^], and you can understand what
HttpClientModule
was the latest update to Angular ecosystem, making
HttpModule
older.
See this too:
Angular Http[
^].
Angular - Http vs HttpClient[
^]
One more thing, please use either one of them as it will cause version and API conflicts later on in the project. So, make a choice and remove the
HttpModule
(
this.http
) from the project and use the latest
HttpClientModule
.