Comments (19)
You can have a look at this repo, its trending api is closed to https://github.com/trending, it maybe have some time lag because of cache, but still awesome.
By the way, this API is used by CodeHub APP now.
from git-point.
I have created a first draft of the approach.
You can read it here. https://github.com/RolfKoenders/gitpoint-api-docs
I'm going to investigate which data we can retrieve by scraping. Since we then have the repository name we could use the API to retrieve more details about that repository and save that in the data store. After we know which data will be stored we can start working on the API calls.
from git-point.
Thank you so much @Huang-Libo that is perfect!!! Makes things so much simpler π π π
from git-point.
@housseindjirdeh You need the auto complete usernames features ;)
I will document a plan and share it to discuss!
from git-point.
I have the API ready you can use that! :D I was working on implementing it but takes me longer then expected to do it properly with the redux system, and i have a busy period.. If you need help let me know.
Until we are going to re-deploy it to the correct account @housseindjirdeh you can use this url:
http://gp-public-160495907.eu-west-1.elb.amazonaws.com/trending/today
Docs: https://github.com/RolfKoenders/gitpoint-api-docs/blob/master/api/swagger.yml
from git-point.
I've tried adding that feature to one of my projects - but GitHub doesn't provide an api specifically for getting the exact data at that url. The solution closest to that is to use the Search API and give it some options. For instance for finding popular API's created in the last day using js:
curl -G https://api.github.com/search/repositories --data-urlencode "sort=stars" --data-urlencode "order=desc" --data-urlencode "q=language:javascript" --data-urlencode "q=created:>
date -v-1d '+%Y-%m-%d'"
But clearly, that doesn't give the same results as https://github.com/trending/javascript
If anyone found a better/actual way of getting trending repos, please share. :)
from git-point.
I really wanted to include this as part of the first release but just like you mentioned @astelvida - there was no direct available endpoint for it :O
Will love to hear any suggestions from anybody on how we can do this. If there is no better solution, I'm okay with using the queried search API just like you mentioned and calling it 'Popular Repositories this past day/week/etc'
from git-point.
In terms of design - I think this can fit perfectly within the Search
screen. Right now we have a placeholder when a search hasn't been made (Search for any repository/user
). I think having the list of popular/trending repositories here would awesome.
We can start with just having popular repositories of today and I would be happy to close this PR with it. We can create a separate ticket to add a toggle of sorts for today/this week/this month if we prefer πΊ
from git-point.
@Huang-Libo That api would definitely work for us!
@housseindjirdeh What would be a nice place to show this? Add an star to the tabbar and show a nice view of the trending repo's? There is not really a 'other' menu option. We could maybe replace the profile with a hamburger icon and show a list of other options?
from git-point.
It might fit well somewhere on the search screen, too.
from git-point.
@andrewda Yea i was thinking that to. As a option next to Repositories & Users? But are we then searching in trending when the user clicks search?
from git-point.
Yea, I was thinking that would be a good spot. How about on that tab instead of a search bar we have a drop down with languages?
note to self: you can use a language parameter on the codehub trending API http://trending.codehub-app.com/v2/trending?language=python
from git-point.
@andrewda That sounds like a nice feature!
from git-point.
@andrewda @RolfKoenders yep on the search screen was exactly what I was thinking, but I don't think it should be a tab besides repos
and users
specifically because it'll seem like users have to search for trending. I was thinking showing a list of trending repositories (and a title) as a placeholder on that screen before the user searches for anything (instead of the message Search for any repository/user
. Does that make sense?
However I do think having a dropdown is a good idea π€ I really like @andrewda's idea but as a user it's an extra step to find trending so I'm leaning towards showing it as a default. Repositories
tab will default to showing trending repositories of today and Users
tab will default to trending users of today. We can later add support of a dropdown to change timelines. How does that sound?
from git-point.
@housseindjirdeh Showing the trending repositories before searching sounds like a nice idea indeed.
Btw, if i am correct the owner of that api stated in the readme to not use those endpoints since its for their app. We could host/setup our own instance of it, or i could build a similar api maybe with some more options/filters we would like. So we can make the api to our needs.
from git-point.
@RolfKoenders thank you for noticing that, I didn't catch that in the README! We definitely can't use those endpoints since that's the case - I would absolutely love if we can set up a similar instance or even one with more options, filters. I hope this won't be too much work however so let's use this and our Gitter channel to chat all the details.
from git-point.
I assigned this issue to myself. Follow up message on the message above this one. Im starting on the actual API at this moment, the next phase is the deployment part and then the actual screens in the app. Follow the progress here
from git-point.
@RolfKoenders I will take it?
from git-point.
@RolfKoenders Thanks, it's cool, I'll see what can be done.
from git-point.
Related Issues (20)
- Layout needs padding on iPhoneXS HOT 1
- Only message βOne of the most feature-rich GitHub clients that siΔ 100% freeβ displayed HOT 1
- The support URL in the app store isn't very useful
- Cannot click on the bottons on iPhone X
- Can't star a repository from iOS device HOT 2
- Failed on iOS, xcode 10 HOT 5
- Make next Android release provide 64-bit versions
- please update ios app store HOT 7
- Create ticket on iOS 12.3.1 crash when submit. HOT 1
- Upgrade to styled-components@4 HOT 1
- Tool used in the main readme prototype HOT 2
- Replace deprecated React lifecycle methods
- Icons missing on iPad HOT 2
- Use Git Data API for files HOT 7
- Multitasking
- Login problem since RN 0.59
- git point crashes user UI (I think) - locks my phone
- Fix all errors on phone HOT 1
- Fix issues HOT 1
- Question
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from git-point.