feat(about): 更新项目过滤逻辑并完善README文档
- 修改项目过滤条件,优先展示有星标或 fork 的项目 - 优化本地环境检测逻辑,避免 undefined 错误 - 在导航栏新增“介绍”页面链接 - 重写 README 文档,丰富项目介绍、特性、技术栈等内容 - 添加项目结构说明和功能模块描述 - 补充部署指南和致谢信息 - 更新许可证和作者信息 - 添加在线预览和相关徽章展示
This commit is contained in:
@@ -190,7 +190,7 @@ function initProjects() {
|
||||
success: function(repos) {
|
||||
// 过滤并排序:优先显示原创项目(非fork),按星数排序
|
||||
var filteredRepos = repos.filter(function(repo) {
|
||||
return !repo.fork; // 过滤掉fork的项目
|
||||
return repo.stargazers_count > 0 || repo.forks_count > 0; // 过滤掉fork的项目
|
||||
}).sort(function(a, b) {
|
||||
return b.stargazers_count - a.stargazers_count; // 按星数降序排序
|
||||
}).slice(0, 12); // 只取前12个
|
||||
|
||||
@@ -131,7 +131,7 @@ const SiteConfig = {
|
||||
|
||||
// 开发环境配置
|
||||
dev: {
|
||||
isLocal: location.hostname.indexOf( 'localhost') > -1 || location.hostname.indexOf( '127.0.0.1') > -1
|
||||
isLocal: (typeof location !== 'undefined') ? (location.hostname.indexOf('localhost') > -1 || location.hostname.indexOf('127.0.0.1') > -1) : false
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user