What is the difference between the paramMap and the queryParamMap on the ActivatedRoute class?
paramMap
queryParamMap
ActivatedRoute
The paramMap is an object literal of the parameters in a route's URL path. The queryParamMap is an Observable of those same parameters.
paramMap is the legacy name from Angular 3. The new name is queryParamMap.
The paramMap is an Observable that contains the parameter values that are part of a route's URL path. The queryParamMap is a method that takes in an array of keys and is used to find specific parameters in the paramMap.
Both are Observables containing values from the requested route's URL string. The paramMap contains the parameter values that are in the URL path and the queryParamMap contains the URL query parameters.