The <webview>
element has an attribute partition
that achieves exactly what is required: you can have separate local browser states, persistent or not, possibly shared between several instances.
Is it possible for two ChromeApp WebViews to have different set of cookies?
-
01-07-2023 - |
题
I have a chrome packaged app, in which I use WebView
s to open external content.
What I would like to achieve is to be able to log in with two different users in a webapp (that uses cookies for storing sessionID).
The problem is that the two WebView
s seem to share the cookies among themselves.
I've searched through the documentation and internet but couldn't find any clues on how to separate cookie-spaces, or if that is even possible?
My guess would be it is not possible, since chrome itself can only run two sessions in parallel (normal & incognito), but I would really be interested to know it for sure, + maybe the reasons behind it.
解决方案
不隶属于 StackOverflow