Run background pages in separate partition
authorCheng Zhao <zcbenz@gmail.com>
Wed, 13 Jul 2016 07:22:55 +0000 (16:22 +0900)
committerCheng Zhao <zcbenz@gmail.com>
Wed, 13 Jul 2016 07:22:55 +0000 (16:22 +0900)
This avoids the default partition always being created on startup, so it
gives users a chance to run session.fromParititon.

lib/browser/chrome-extension.js

index d8d0f78..96f7508 100644 (file)
@@ -86,6 +86,7 @@ const startBackgroundPages = function (manifest) {
   }
 
   const contents = webContents.create({
+    partition: 'persist:__chrome_extension',
     isBackgroundPage: true,
     commandLineSwitches: ['--background-page']
   })