MetaMask / providers

An Ethereum Provider that connects over a stream, as injected into websites by MetaMask
MIT License
225 stars 124 forks source link

HELP - Can the port stream based provider work in a tab application loaded by the extension? #284

Open javaspeak opened 1 year ago

javaspeak commented 1 year ago

Can the port stream based provider work in a tab application loaded by the extension?

i.e. when a background script opens a chrome extension app in a tab - can the chrome extension app connect to MetaMask?

I am not talking about content scripts. I am talking about a chrome extension app opening in a new tab.

The reason I wanted to connect to the web browser version of metamask in the tab was so that it is associated with the extension url:

chrome-extension://oahhaapnfpkfnbgeopliehfgenifngde/tab.html#register

and not the url the content script happens to be on.

If it is not possible to connect to Meta Mask in a chrome extension tab app, then is there another way to connect the meta mask browser wallet to a domain url like:

chrome-extension://oahhaapnfpkfnbgeopliehfgenifngde/tab.html#register

I am super struggling finding the answers to this so if anyone can help me I will be super happy.

Thanks for your time.

javaspeak commented 1 year ago

Anyone?

mcmire commented 12 months ago

Hi @javaspeak, sorry for the late reply. MetaMask has a "full-screen view" that opens in another tab, and ports work across extension-related views, so it should be possible to do what you say. But if you are having trouble, could you give us more information on what you've tried so we can help you further?

divinit7 commented 9 months ago

Hey, @javaspeak . Any progress on this?

mcmire commented 8 months ago

@divinit7 Not sure what you mean by "progress" here, but are you having a similar issue?