@@ -26,11 +26,6 @@ <h2>Welcome to the Machine Learning Repositories</h2>
26
26
< p > This website provides an overview of various machine learning repositories available on GitHub, brought to you by the RecodeHive organization.</ p >
27
27
< a href ="https://github.com/recodehive/machine-learning-repos " class ="cta-button "> Visit the Repository</ a >
28
28
</ section > .
29
- < section id ="repo-list ">
30
- < h2 > Repositories</ h2 >
31
- < ul id ="directories ">
32
- </ ul >
33
- </ section >
34
29
35
30
<!-- Repository Information -->
36
31
< section id ="repository-info ">
@@ -82,23 +77,12 @@ <h3>Most Used Language</h3>
82
77
</ div >
83
78
</ section >
84
79
85
- <!-- Contributors -->
86
- < section id ="contributors ">
87
- < h2 > Contributors</ h2 >
88
- < div id ="contributors-list " class ="contributors-grid "> </ div >
89
- </ section >
90
-
91
- <!-- Languages -->
92
- < section id ="languages ">
93
- < h2 > Languages Used</ h2 >
94
- < ul id ="language-list "> </ ul >
80
+ < section id ="repo-list ">
81
+ < h2 > Repositories</ h2 >
82
+ < ul id ="directories ">
83
+ </ ul >
95
84
</ section >
96
85
97
- <!-- Milestones -->
98
- < section id ="milestones ">
99
- < h2 > Project Milestones</ h2 >
100
- < div id ="milestones-chart " class ="milestones-grid "> </ div >
101
- </ section >
102
86
</ main >
103
87
104
88
< footer >
@@ -131,10 +115,6 @@ <h2>Project Milestones</h2>
131
115
document . getElementById ( 'license' ) . innerText = repoData . license ? repoData . license . spdx_id : 'No License' ;
132
116
document . getElementById ( 'repo-size' ) . innerText = ( repoData . size / 1024 ) . toFixed ( 2 ) + ' MB' ;
133
117
134
- // Fetch number of contributors
135
- const contributorsResponse = await fetch ( `${ apiUrl } /contributors` ) ;
136
- const contributorsData = await contributorsResponse . json ( ) ;
137
- document . getElementById ( 'contributors-count' ) . innerText = contributorsData . length ;
138
118
139
119
// Fetch languages
140
120
const languagesResponse = await fetch ( `${ apiUrl } /languages` ) ;
@@ -163,35 +143,7 @@ <h2>Project Milestones</h2>
163
143
// Replace this with a dynamic calculation if you have a method to determine the total number of projects
164
144
document . getElementById ( 'total-projects' ) . innerText = "10" ;
165
145
166
- // Fetch milestones (if any)
167
- const milestonesResponse = await fetch ( `${ apiUrl } /milestones` ) ;
168
- const milestonesData = await milestonesResponse . json ( ) ;
169
- const milestonesChart = document . getElementById ( 'milestones-chart' ) ;
170
-
171
- milestonesData . forEach ( milestone => {
172
- const milestoneDiv = document . createElement ( 'div' ) ;
173
- milestoneDiv . className = 'milestone' ;
174
- milestoneDiv . innerHTML = `
175
- <h4>${ milestone . title } </h4>
176
- <div class="progress">
177
- <div class="progress-bar" style="width: ${ ( milestone . closed_issues / ( milestone . open_issues + milestone . closed_issues ) ) * 100 } %;"></div>
178
- </div>
179
- ` ;
180
- milestonesChart . appendChild ( milestoneDiv ) ;
181
- } ) ;
182
-
183
- // Populate contributors list
184
- const contributorsList = document . getElementById ( 'contributors-list' ) ;
185
- contributorsData . forEach ( contributor => {
186
- const contributorCard = document . createElement ( 'div' ) ;
187
- contributorCard . className = 'contributor-card' ;
188
- contributorCard . innerHTML = `
189
- <a href="${ contributor . html_url } " target="_blank">
190
- <img src="${ contributor . avatar_url } " alt="${ contributor . login } ">
191
- </a>
192
- ` ;
193
- contributorsList . appendChild ( contributorCard ) ;
194
- } ) ;
146
+
195
147
196
148
} catch ( error ) {
197
149
console . error ( 'Error fetching data from GitHub API:' , error ) ;
0 commit comments