42 questions
1
vote
1
answer
211
views
How to use ngx-cookie-service-ssr in Angular 19 with SSR
I'm trying to setup ngx-cookie-service-ssr for my project. However, in the set up description,
It's mentioned that I have to replace this code in the server.ts
server.get('*', (req, res) => {
res....
2
votes
2
answers
100
views
Angular Guard Issue with Server-Side Rendering (SSR)
I'm working on an Angular 17 project with login and session functionality. Everything is working well except for the guard. Every time I refresh the page, the screen briefly blinks back to the login ...
1
vote
1
answer
43
views
How to retrieve a value from ngx-cookie-service before the app loads?
I'm encountering an issue when a user reloads the page. On app startup, there’s a brief delay (100-400ms) needed to retrieve a value from the cookie. During this time, the user is briefly redirected ...
2
votes
1
answer
273
views
NullInjectorError: No provider for CookieService! Angular 17+
With the new Dependency injection and standalone applications its a bit unclear to me how I provide a custom library at root.
I tried to install ngx-cookie but I want to use it at service level, which ...
1
vote
1
answer
204
views
Cannot get the current user information from the cookies when a new user logs in
I'm using ngx-cookie-service module in my Angular app to store user related information like "username" or "userId" temporarily. For the first user trying to log in to the app, the ...
0
votes
1
answer
223
views
ngx-cookie-service is not returning the data on page refresh
I am using ngx-cookie-service and setting the values on login
login() {
this.loading = true;
this.loginServie.login(this.model)
.pipe(
catchError(error => {
this....
0
votes
1
answer
366
views
What's the best way to show the cookie value in the template using observables + selectors with ngx-cookie-service?
I'm curious is there a nice way to use observables to get a cookie value in real time, a "reactive" cookie?
The possible solutions show using this.cookieService.get("cookieName) in ...
0
votes
1
answer
128
views
AWS auth Cookie storage is not encoding the plus(+) character
I have the below code
const config = awsconfig;
config.cookieStorage = { domain: "mydomain", path: "/", expires: 365, sameSite: "lax", secure: true };
For example, if ...
0
votes
2
answers
530
views
ngx-cookie-service is giving me Error: NG0203, what am i doing wrong?
i"m currently working on a LoginComponent in my Angular app. When i want to press the button that navigates to it i get the following error:
core.mjs:10572 ERROR Error: Uncaught (in promise): ...
0
votes
0
answers
436
views
NG0200: Circular dependency in DI detected while instantiating a provider / NG0203:
I'm currently working on a login component in my Angular front-end. I get this error upon clicking towards the button that navigates to the LoginComponent:
ERROR Error: Uncaught (in promise): Error: ...
1
vote
0
answers
6k
views
how to GET a specific cookie value in Angular 14
"I'm using the ngx-cookie-service library in my Angular application, but I'm getting two different cookies on every login as already the session id has been SET in the backend, to GET the correct ...
0
votes
1
answer
562
views
ngx-cookie-service does not send Cookies in Angular/Ionic
Angular 16
Ionic 7
ngx-cookie-service 16
With this.cookieService.set('sessionkey', 'a-unique-hash', null, null, null, false, 'Lax'); or this.cookieService.set('sessionkey', 'a-unique-hash'); i set a ...
1
vote
2
answers
2k
views
Cannot install ngx-cookie-service in angular project
I am working on an angular project in where I need to use cookies.
I am installing ngx-cookie-service module from https://www.npmjs.com/package/ngx-cookie-service
But the module is not being installed,...
1
vote
2
answers
2k
views
Unit Test Error when having CookieService as argument in constructor of tested component
I would like to test a function. To call that function in unit test I need to create an instance of the component class.
The component class contains different services as arguments in the constructor ...
0
votes
1
answer
1k
views
Angular ngx-cookie-service is lost when browser is closed
I am trying to set a cookie with ngx-cookie-service to be able to retrieve it later
The code is working fine when refreshing and the cookie is present in the chrome developer tools - Applications - ...