0

I am using redux-cookies-middleware and there I can pass just name and value for the cookies. But if I need to add path how should I pass it?

{ session: { name: 'session' // name of the cookie in which the value of session will be synced }, 'auth.token': { name: 'auth_token' // name of the cookie in which the value of auth.token will be synced } }

Serhii Minin
  • 47
  • 1
  • 8

1 Answers1

0

You will need to use the setCookie option when initializing your middleware. This is a placeholder for a function to be called when setting cookies. Once you have a custom function for setting cookies you will have more control over things like path, domain, expiry, etc..