Chrome extension: Access to variables of a background.js from a popup.js

galtraub

New Member
If I'm using chrome.extension.getBackgroundPage(), I can access to variables of the background.js like this:background.js:\[code\]var transfer = 'some text';\[/code\]popup.js:\[code\]chrome.extension.getBackgroundPage().transfer\[/code\]But there has said I gets only a window object (but may be 'JavaScript' before 'window' means something...). Why can I access to background variables?
 
Back
Top