-
-
Notifications
You must be signed in to change notification settings - Fork 28
Closed
Description
🚀 Feature Proposal
Currently the httpOnly flag is set to false here:
| httpOnly: false, |
The proposal is to allow the flag to be set via the detector options in the same way as the cookie domain, path and sameSite options - e.g. cookieHttpOnly: true.
Motivation
This would prevent client-side scripts from accessing or manipulating the language cookie.
Example
detection: {
order: ['querystring', 'path', 'cookie', 'header'],
lookupQuerystring: 'lang',
lookupPath: 'lang',
lookupCookie: 'lang',
lookupHeader: 'accept-language',
caches: ['cookie'],
cookieDomain: 'example.com',
cookieSecure: true,
cookieSameSite: 'strict',
cookieHttpOnly: true
}
Metadata
Metadata
Assignees
Labels
No labels