I have an Angular application which on start up should read Cookies (app.component.ts) and should redirect to a new component passing the read values. How can I do this?
Currently, my server provides the required values as html tag attributes to <app-root> (eg <app-root something="someValue">) and the AppComponent reads the attributes using this.el.nativeElement.getAttribute("somethings"). Though it works, I'll prefer to read the values from Cookies or from say an HTTP Header
Is there a way to do this?