Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
just generate random number between 0 and the most recent post ID, generate a dozen or so at a time and voilà, easy random selection from a DB.
-
@sheeponmeth your solution would work if looking at 10 or 20 rants but if looking at an infinite scrolling page then you would potentially end up with duplicates.
I'd be happy with a "random" button displaying only 10 random rants. I would spam that button haha -
Duplicates would be just as rare as unique values, though. And the app/web page only serves a set of rants at a time, so the infinite aspect is not a worry given that most of these guys have work to get back to.
-
IAL322249yNot so simple
You have to keep track of the already shown posts each time you want to load more rants, for example
Maybe a easier way to show random rants is to show just a fixed number of them, and to see other rants, just "refresh" the page, showing other results. No extra-load on the server, and easier to implement -
dfox426039yGreat technical discussion, I like it :)
Putting any technical difficulties aside, is this a feature you think you would enjoy? We can definitely do something like this if there's enough demand! -
dfox426039y@sheeponmeth how would it ideally work if it could do anything?
Just in random sort order? I think maybe only rants that have over a certain amount of +1's, maybe 15.
And another idea - what about a new kind of screen that just shows one rant at a time and you tap to see another random one? Maybe same rule with only rants that have 15 or more +1's or something. Feedback on this is appreciated! -
@dfox I think swiping through to new ones would be cool. Kind of like Tinder I guess? I've never actually used it.
I think giving a min likes would create a bias for those who already have likes => min, but then again, maybe a user specified min? I think random is to find the ones that don't make it to the top. I think something as random as possible would be most favorable. -
IAL322249y@sheeponmeth Great idea! And yeah, a minimum amount of +1's would definitely avoid some posts to get visibility
-
with an option "image only" so we don't get the rants from people blogging their lives :)
We need a filter "sort by: random"
undefined