-
-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
To make sure all the sendMessage() are cross-platfroms #325
Comments
I would like to work on this issue, but would you please describe the issue to me a little bit more in detail (I'm a beginner, so please excuse me)? Thanks! |
Hello @sathuhebbar , I will explain this issue to you Uli is a browser extension that primarily works on two browsers - Chrome and Firefox Each browser extension has a file called Communication between extensions and their content scripts works by using message passing. Either side can listen for messages sent from the other end, and respond on the same channel. If you only need to send a single message to another part of your extension (and optionally get a response back), we can use a thing called Since we essentially have the same code for the browser extension to run in chrome and firefox. It is important that we make A good example of cross-platform code in Uli can be found here. Uli/browser-extension/plugin/src/ui-components/pages/App.jsx Lines 69 to 83 in fc3f078
In the above code snipppet, we first identify which browser it is and then store it in the userBrowserTabs variable. Next to use sendMessage() , in the same we file, we do it like thisUli/browser-extension/plugin/src/ui-components/pages/App.jsx Lines 103 to 135 in fc3f078
As you can see, in this function, sendMessage() is made cross-platform.
What should be done in the Issue?There is a code snippet in this file, where
We don't want that, the issue is to make this cross-platform. To work on this Issue
PS - Please dont hesitate to reach out to us if you face any issue. Feel free to join our Slack and interact with us |
Hi @aatmanvaidya Thank you and all maintainers for this project! Can I work on this issue? Though I haven't worked with browser extensions before, I do have experience writing JavaScript. I think it'll be a good learning experience for me. |
Hello @abhishek-nigam, please feel free to take this issue up, experience with JavaScript is always a plus. To setup the Uli browser extension:
If you wish to take this issue up, let me know, I will assign it to you Feel free to reach out, if you need any help |
Thanks! Sure @aatmanvaidya, I'll work on it |
Hi @aatmanvaidya , I'm having an issue getting the dev setup to run. I followed the YouTube walkthrough as well as the Wiki guide. But as soon as I click on the extension's icon in Chrome, it gives some errors which are collected by Chrome and shown. I have made a screen recording to show the error: Screencast.from.10-10-2023.11.15.34.PM.webmCould you help me with it? |
Hi @abhishek-nigam , what happens when you click on Still, if its convenient, for you, join our slack (link in readme), we can get on a call and I can help you fix this. you can drop a message in the |
Sure @aatmanvaidya I'll go ahead and do that. |
Hi, I've raised a PR for it here #401 @aatmanvaidya |
Hi @abhishek-nigam , will take a look soon, hope you were able to run the browser extension? |
Nope, I wasn't able to run the extension. Nothing happens when I click on 'Activate Account' |
This issue has been resolved - #401 |
Currently, the sendMessage() is being called via chrome, instead, it should be cross platform (firefox etc.).
Uli/browser-extension/plugin/src/background.js
Lines 13 to 34 in 20c1eaf
The text was updated successfully, but these errors were encountered: