mirror of
https://github.com/Gar-b-age/CookLikeHOC.git
synced 2026-08-12 14:21:02 +00:00
@@ -42,7 +42,7 @@ export function generateNavAndSidebar(rootDir: string) {
|
|||||||
|
|
||||||
for (const dir of sections) {
|
for (const dir of sections) {
|
||||||
const abs = path.join(rootDir, dir)
|
const abs = path.join(rootDir, dir)
|
||||||
const files = fs
|
const files = fs
|
||||||
.readdirSync(abs)
|
.readdirSync(abs)
|
||||||
.filter((f) => isMarkdown(path.join(abs, f)))
|
.filter((f) => isMarkdown(path.join(abs, f)))
|
||||||
.sort(sortByPinyinOrName)
|
.sort(sortByPinyinOrName)
|
||||||
@@ -50,9 +50,12 @@ export function generateNavAndSidebar(rootDir: string) {
|
|||||||
// Build sidebar for this section
|
// Build sidebar for this section
|
||||||
const items: SidebarItem[] = files.map((f) => ({
|
const items: SidebarItem[] = files.map((f) => ({
|
||||||
text: titleFromName(f),
|
text: titleFromName(f),
|
||||||
link: `/${encodeURI(dir)}/${encodeURI(f)}`,
|
link: `/${encodeURI(dir)}/${encodeURI(f)}`,
|
||||||
}))
|
}))
|
||||||
|
|
||||||
|
// Find README.md、readme.md、index.md
|
||||||
|
const readme = ['README.md', 'readme.md', 'index.md'].find((n) => fs.existsSync(path.join(abs, n)))
|
||||||
|
|
||||||
if (items.length > 0) {
|
if (items.length > 0) {
|
||||||
sidebar[`/${dir}/`] = [
|
sidebar[`/${dir}/`] = [
|
||||||
{
|
{
|
||||||
@@ -60,11 +63,12 @@ export function generateNavAndSidebar(rootDir: string) {
|
|||||||
items,
|
items,
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
if (readme) {
|
||||||
// First doc becomes nav link for section
|
nav.push({ text: dir, link: `/${encodeURI(dir)}/${encodeURI(readme)}` })
|
||||||
nav.push({ text: dir, link: items[0].link! })
|
} else {
|
||||||
|
nav.push({ text: dir, link: items[0].link! })
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
// Empty section: still show in nav to directory index if exists
|
|
||||||
nav.push({ text: dir, link: `/${encodeURI(dir)}/` })
|
nav.push({ text: dir, link: `/${encodeURI(dir)}/` })
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,9 +2,13 @@
|
|||||||
|
|
||||||
# 像老乡鸡那样做饭
|
# 像老乡鸡那样做饭
|
||||||
|
|
||||||
|
[**一些说明**](https://github.com/Gar-b-age/CookLikeHOC/issues/26)
|
||||||
|
|
||||||
|
仓库主体部分于2024年完工,和2025年9月份的舆论事件无关。截止提交时,仓库的贡献者们与老乡鸡的唯一关系只有消费者和商家的关系。本仓库不是老乡鸡的官方仓库。如果有任何问题或意见建议,欢迎指出
|
||||||
|
|
||||||
**新更新**
|
**新更新**
|
||||||
|
|
||||||
- 炖菜部分已上线部分由ai配图的菜品,欢迎大家来贡献实拍图
|
- 炖菜已上线部分由ai配图的菜品,但更欢迎大家来贡献实拍图
|
||||||
|
|
||||||
- 现已上线网页端,[点击访问](https://cooklikehoc.soilzhu.su)
|
- 现已上线网页端,[点击访问](https://cooklikehoc.soilzhu.su)
|
||||||
|
|
||||||
@@ -14,7 +18,7 @@
|
|||||||
|
|
||||||
文字超大段copy自[《老乡鸡菜品溯源报告》](https://www.lxjchina.com.cn/display.asp?id=4226),有编辑与整理
|
文字超大段copy自[《老乡鸡菜品溯源报告》](https://www.lxjchina.com.cn/display.asp?id=4226),有编辑与整理
|
||||||
|
|
||||||
指路隔壁 [How To Cook](https://cook.aiurs.co/)
|
指路隔壁 [How To Cook](https://cook.aiursoft.cn/)
|
||||||
|
|
||||||
至于为什么仓库名要叫CookLikeHOC,因为直接写Laoxiangji大概不方便阅读,而Home Original Chicken是china daily报道中所使用的老乡鸡的英文名,故简写成HOC。
|
至于为什么仓库名要叫CookLikeHOC,因为直接写Laoxiangji大概不方便阅读,而Home Original Chicken是china daily报道中所使用的老乡鸡的英文名,故简写成HOC。
|
||||||
|
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ hero:
|
|||||||
actions:
|
actions:
|
||||||
- theme: brand
|
- theme: brand
|
||||||
text: 开始浏览
|
text: 开始浏览
|
||||||
link: /炒菜/菠萝咕咾肉
|
link: /炒菜/README
|
||||||
- theme: alt
|
- theme: alt
|
||||||
text: GitHub
|
text: GitHub
|
||||||
link: https://github.com/Gar-b-age/CookLikeHOC
|
link: https://github.com/Gar-b-age/CookLikeHOC
|
||||||
|
|||||||
@@ -0,0 +1,7 @@
|
|||||||
|
# 奶黄鸡包
|
||||||
|
|
||||||
|
## 配料
|
||||||
|
- 奶黄鸡包(小麦粉、玉米粉、鸡蛋、白砂糖等)(来自郑州千味央厨)
|
||||||
|
|
||||||
|
## 步骤
|
||||||
|
- 蒸柜上汽后,蒸制 8 分钟。
|
||||||
+2
-2
@@ -1,7 +1,7 @@
|
|||||||
# 荠菜鲜肉蒸饺
|
# 荠菜鲜肉蒸饺
|
||||||
|
|
||||||
## 配料
|
## 配料
|
||||||
- 奶黄鸡包(来自郑州千味央厨)
|
- 荠菜鲜肉蒸饺(小麦粉、猪肉、荠菜、盐、鸡精等)(来自郑州千味央厨、山东康喜)
|
||||||
|
|
||||||
## 步骤
|
## 步骤
|
||||||
- 蒸柜上汽后,蒸制 8 分钟。
|
- 蒸柜上汽后,蒸制 10 分钟。
|
||||||
Reference in New Issue
Block a user