mirror of
https://github.com/bitwarden/browser.git
synced 2024-11-20 11:25:37 +01:00
WIP desktop communication
This commit is contained in:
parent
2e20192f1b
commit
296ccb6829
@ -4,3 +4,13 @@ const bitwardenMain = (window as any).bitwardenMain = new MainBackground();
|
||||
bitwardenMain.bootstrap().then(() => {
|
||||
// Finished bootstrapping
|
||||
});
|
||||
|
||||
const port = chrome.runtime.connectNative('com.8bit.bitwarden');
|
||||
|
||||
port.onMessage.addListener((msg: any) => {
|
||||
console.log('Received' + msg);
|
||||
});
|
||||
port.onDisconnect.addListener(() => {
|
||||
console.log('Disconnected');
|
||||
});
|
||||
port.postMessage({ text: 'Hello, my_application' });
|
||||
|
@ -89,7 +89,8 @@
|
||||
"http://*/*",
|
||||
"https://*/*",
|
||||
"webRequest",
|
||||
"webRequestBlocking"
|
||||
"webRequestBlocking",
|
||||
"nativeMessaging"
|
||||
],
|
||||
"content_security_policy": "script-src 'self' 'unsafe-eval'; object-src 'self'",
|
||||
"commands": {
|
||||
|
Loading…
Reference in New Issue
Block a user