3 ms·
Nice idea ! How do you handle duplicates ?
by hugopuybareau 2mo ago
Nice idea ! How do you handle duplicates ?
- twalichiewicz 2mo ago[Assuming you mean duplicate HN submissions] I normalize the URL and use HN's Algolia search API to find an existing story with a matching URL. I don't currently handle multiple HN submissions of the same article; I just use the matching story I find. That being said, I could see creating a historical snapshot of all the times an article has been submitted and building a blended comments section in the future.
- Barbing 2mo agoBlended comments section sounds great! Good work.
- twalichiewicz 2mo agoCrunched a bit and got a first pass of this working. https://github.com/twalichiewicz/HNewhere/releases/tag/v1.4.0 https://github.com/twalichiewicz/HNewhere/releases/tag/v1.4.... You can test with https://www.apple.com/iphone/ https://www.apple.com/iphone/