mirror of
https://github.com/MacRimi/ProxMenux.git
synced 2025-07-06 23:46:52 +00:00
Update page.tsx
This commit is contained in:
parent
081958dfb1
commit
92435a088f
@ -3,7 +3,7 @@ import fs from "fs"
|
|||||||
import path from "path"
|
import path from "path"
|
||||||
import matter from "gray-matter"
|
import matter from "gray-matter"
|
||||||
import Link from "next/link"
|
import Link from "next/link"
|
||||||
import Footer from "@/components/footer"
|
import Footer from "@/components/footer2"
|
||||||
|
|
||||||
const guidesDirectory = path.join(process.cwd(), "..", "guides")
|
const guidesDirectory = path.join(process.cwd(), "..", "guides")
|
||||||
|
|
||||||
@ -26,7 +26,7 @@ function getGuides(): Guide[] {
|
|||||||
} else if (entry.isFile() && entry.name.endsWith(".md")) {
|
} else if (entry.isFile() && entry.name.endsWith(".md")) {
|
||||||
const slug = relativePath.replace(/\.md$/, "")
|
const slug = relativePath.replace(/\.md$/, "")
|
||||||
|
|
||||||
// 🔹 Extraer metadatos usando gray-matter
|
|
||||||
const fileContents = fs.readFileSync(fullPath, "utf8")
|
const fileContents = fs.readFileSync(fullPath, "utf8")
|
||||||
const { data } = matter(fileContents)
|
const { data } = matter(fileContents)
|
||||||
|
|
||||||
@ -64,7 +64,7 @@ export default function GuidesPage() {
|
|||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<Footer />
|
<Footer2 />
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user