Hacker News new | past | comments | ask | show | jobs | submit login

Take the code from Firefox iOS or Android-components. We spent a lot of time on these and it is all on device.

https://github.com/mozilla-mobile/android-components

https://github.com/mozilla-mobile/Firefox-iOS




I wonder how many lines of code from big open source applications are generic enough to be reused in other projects.

Firefox and Google Chrome probably have the equivalent of many small high quality libraries embedded in them, implementing 'business' logic or protocols, that could be reused in more places.

I guess a large scale study on github could be done, with a graph analysis to show potential "cut off" points in codebase.


This is one of the goals of our Android-components project. Take a peek. Many components are reusable across browsers/applications.


One issue is that if a bunch of code of a similar theme can be broken off, many times it will be (depending on the culture of the software team). Is looking at the source code of a big project with a hundred dependencies that were all libraries spun off to support the project different to looking at a project where people tried to keep everything monolithic (where you’d expect better re-use potential per line-of-code?)


Yeah... the gesture is nice, but good luck extracting any code from a massive project. Might as well say “Here’s some free oil; all you have to do is dig for it.” Unlike oil, this might not be worth the excavation.

It’s a bit telling that they linked to the GitHub repositories rather than specific lines of code they were talking about.


Here's their kotlin implemenation, looks fairly straightforward/self-contained: https://github.com/mozilla-mobile/android-components/tree/ma...


Android components is a foundational technology for our browser products on Android but also for many other applications. We’ve designed things in such a way that you can pull in just those things that you need. If that is not the case, file an issue and we will take a look at how to improve things.


Looking at the iOS project linked, https://github.com/mozilla-mobile/firefox-ios/blob/76faae8c6... , other than being written swift, it looks pretty self-contained/ok?


There is also a content script I think and storage for these icons and their meta data. It is probably less generic on iOS than on Android but should be fairly simply to take some big chunks for reuse.


Yeah, let's violate privacy instead.


What a world class reply. This is what makes open source valuable.


Yes, apart from Chrome's implementation there is probably no better tested and more mature implementation. Still it seems to be a non-trivial problem because Firefox sometimes shows me a favicon from another site I used.


Why don't they just take the code from their "internal favicon service"? The whole thing smells.


If you don't visit the site explicitly, just have the site somewhere in a list/bookmark/whatever, that site now has your IP address and basic header info when it needs to go retrieve it. By going through DDG, the site has a bot hit.

To me it looks to be trying to uphold your anonimity until you commit (click) through to the site/link. But certainly other ways they can approach this if it really bothers people.. I'd prefer DDG doing the lookup.. or having no fav icons.. over my computer going and downloading all my bookmark or other source icons


It's probably not written in Java.


[flagged]


I think you're being downvoted because you chose to piggyback your comment on a seemingly unrelated one at the top, are being vitriolic, and didn't back up your claims with respect to their intent and refusal to change this.


Well it's related because Mozilla actually cares about your privacy vs DuckDuckGo which obviously could care less from their reaction to this issue. Their refusal to change this is all the proof you need to know. I dont even use DDG I use Google I just think its funny they have a "Privacy browser" that sends all the sites you visit back to their servers


It is not relevant to this sub-thread, and should have been a new top-level comment.


It's a direct reply to a comment on the sub-thread.


This is nonsense. DDG cares deeply.

We all, including Mozilla!, have made design decisions that in hindsight could have been better.

The important thing here is dialogue and change. And both are happening.


(parent edited comment, can't delete this)


That bit was unnecessary, and pretty tone-deaf given the current socio-political climate.

So let’s call them out on that, briefly, then get on with the argument.


It's not immediately obvious whether it is more privacy preserving if the client automatically makes a request to each site in the search results while scrolling through the results, especially since you're already trusting DDG when performing the search.

Maybe this should be an opt-in rather than an opt-out feature?

Edit: as pointed out by warpspin in another comment, this is about the DDG Browser, not search results.


Scrolling through results is not a good place to ping websites for their icon. Not from a technical perspective but also not from a privacy perspective.

This is mostly a UX issue IMO.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: