sudo-rgorai / DarkSite

A chrome extension to embrace your Dark Side!
MIT License
11 stars 19 forks source link

Dse #61

Closed Harshit850 closed 3 years ago

Harshit850 commented 3 years ago

What is the change?

Search Engine Added.

Which issue does this resolve?

Fixes: #56

What does it fix/add?

User can now switch between multiple search engine.

How was it tested?

On browser

Harshit850 commented 3 years ago

@sudo-rgorai issue #56 is fixed, can i also fix #43?

sudo-rgorai commented 3 years ago

Hey @Harshit850. Are you sure that the search is functional? I tried changing the search option but it always redirected me to google.

Harshit850 commented 3 years ago

@sudo-rgorai i have tested it in my browser it's working fine, but if you saying this than i will check it again.

Harshit850 commented 3 years ago

@sudo-rgorai Look at the page i deployed using github pages, just for the sake of proof that the search engines are working fine. You can check it here :- https://harshit850.github.io/DarkSite/

Once you are done i will delete this page.

sudo-rgorai commented 3 years ago

The changes seem to work perfectly on the webapp. However, I wasn't able to make it work on my local device.

Kazam-screencast-00000

I didn't have an opportunity to go through the code in detail. I shall try to figure out why this is happening. I'm a bit preoccupied so it may take a while. My apologies for that.

If you have any idea about this discrepancy, please do share. Meanwhile, it'll be great if you can remove the extension from your browser, make a fresh clone and test it again. You can also test it on another device if that is possible on your end. Do let me know if you find something. Thanks.

Harshit850 commented 3 years ago

The changes seem to work perfectly on the webapp. However, I wasn't able to make it work on my local device.

Kazam-screencast-00000

I didn't have an opportunity to go through the code in detail. I shall try to figure out why this is happening. I'm a bit preoccupied so it may take a while. My apologies for that.

If you have any idea about this discrepancy, please do share. Meanwhile, it'll be great if you can remove the extension from your browser, make a fresh clone and test it again. You can also test it on another device if that is possible on your end. Do let me know if you find something. Thanks.

Well i think you should try to run it on different browser, or try to clear local storage. On my side i will test it on some another computer and will contact you further.

Harshit850 commented 3 years ago

@sudo-rgorai on my side everything is good, I have checked it on 5 systems all the search engine are working fine.

sudo-rgorai commented 3 years ago

Hey @Harshit850. I finally got time to review the changes and found out why the code broke on my device. Since you had chosen to use JQuery, it wasn't processed well by the browser. My guess is that the discrepancy arose due to mismatching chrome versions or outdated JQuery version. I replaced parts of your code with vanilla JavaScript and it started working. I also introduced cookies for remembering user's choice for default search engine.

Currently, the search engine is functional as expected. However there are problems with DuckDuckGo but I think we can't do much about that. Rest everything is awesome.

Thanks for the help! :relaxed:

Harshit850 commented 3 years ago

@sudo-rgorai Finally we did it, it's been a awesome project to contribute on, thanks to you for having me in this project. Looking forward to fix more issues. And lastly the idea of using cookies to save user choice is awesome, WELL DONE!!!