Skip to content

Commit cb1c92b

Browse files
committed
Update ReadMe
1 parent 6656e73 commit cb1c92b

File tree

11 files changed

+46
-36
lines changed

11 files changed

+46
-36
lines changed

README.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,6 @@
44
<a href="https://gitglance.vercel.app/">View Demo</a>
55
·
66
<a href="https://github.com/devXprite/gitglance/issues/new?assignees=&labels=bug&template=bug_report.md&title=">Report Bug</a>
7-
·
8-
<a href="https://github.com/devXprite/gitglance/issues">Request Feature</a>
97
</p>
108
<br/>
119

@@ -19,6 +17,17 @@
1917
- **Next.js & Tailwind CSS:** Built with Next.js for efficient server-side rendering and Tailwind CSS for easy styling and customization.
2018
- **Responsive Design:** GitGlance is designed to be responsive, ensuring a seamless experience across various devices and screen sizes.
2119

20+
## Screenshots
21+
22+
<!-- <img > -->
23+
<img src="./public/screenshots/1.png" width="45%" />
24+
<img src="./public/screenshots/2.png" width="45%" />
25+
<img src="./public/screenshots/3.png" width="45%" />
26+
<img src="./public/screenshots/4.png" width="45%" />
27+
<img src="./public/screenshots/5.png" width="45%" />
28+
<img src="./public/screenshots/6.png" width="45%" />
29+
30+
2231
## Installation
2332
To run GitGlance locally, follow these steps:
2433

app/[username]/page.js

Lines changed: 26 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -35,35 +35,36 @@ const page = async ({ params: { username } }) => {
3535
console.log('Username:', username);
3636

3737
const userInfo = await fetchUserInfo(username);
38-
// console.log(userInfo);
3938
if (!userInfo) return notFound();
4039

41-
await RecentProfiles.findOneAndUpdate(
42-
{ username },
40+
const updateRecentProfilesDb = async () =>
41+
await RecentProfiles.findOneAndUpdate(
42+
{ username },
43+
{
44+
name: userInfo.name ?? userInfo.username,
45+
username: userInfo.username,
46+
following: userInfo.following.totalCount,
47+
followers: userInfo.followers.totalCount,
48+
avatarUrl: userInfo.avatarUrl,
49+
},
50+
{ upsert: true, new: true, setDefaultsOnInsert: true },
51+
);
52+
53+
const [
54+
userActivity,
4355
{
44-
name: userInfo.name ?? userInfo.username,
45-
username: userInfo.username,
46-
following: userInfo.following.totalCount,
47-
followers: userInfo.followers.totalCount,
48-
avatarUrl: userInfo.avatarUrl,
56+
languagesSize,
57+
contributionCalendar,
58+
commitsPerRepo,
59+
starsPerRepo,
60+
reposPerLanguages,
61+
starsPerLanguages,
62+
popularRepositories,
63+
userStats,
64+
topContributions,
65+
followUp,
4966
},
50-
{ upsert: true, new: true, setDefaultsOnInsert: true },
51-
);
52-
53-
const userActivity = await fetchActivity(username);
54-
55-
const {
56-
languagesSize,
57-
contributionCalendar,
58-
commitsPerRepo,
59-
starsPerRepo,
60-
reposPerLanguages,
61-
starsPerLanguages,
62-
popularRepositories,
63-
userStats,
64-
topContributions,
65-
followUp,
66-
} = await fetchUserData(username);
67+
] = await Promise.all([fetchActivity(username), fetchUserData(username), updateRecentProfilesDb()]);
6768

6869
return (
6970
<main className="mx-auto max-w-screen-xl space-y-8 px-3 pb-10 md:space-y-16">

lib/getRecentProfiles.js

Whitespace-only changes.

public/logo.jpeg

-10.6 KB
Binary file not shown.

public/screenshots/1.png

438 KB
Loading

public/screenshots/2.png

366 KB
Loading

public/screenshots/3.png

530 KB
Loading

public/screenshots/4.png

647 KB
Loading

public/screenshots/5.png

494 KB
Loading

public/screenshots/6.png

380 KB
Loading

0 commit comments

Comments
 (0)