refactor(content): migrate index page to Nuxt Content

This commit refactors the index page to source its content from @nuxt/content, replacing the previous implementation that used i18n
JSON files and hardcoded data within the component.

Key changes:
- Introduced `content.config.ts` to define collections and Zod schemas for type-safe content.
- Moved page content into localized YAML files (`content/en-US/index.yml` and `content/zh-CN/index.yml`).
- Updated `app/pages/index.vue` to fetch data dynamically using `useAsyncData` and `queryCollection`.
- Removed redundant content from i18n JSON files and the Vue component script.

This change decouples content from presentation, improves maintainability, and centralizes content management.
This commit is contained in:
xiaomai
2025-11-05 17:54:59 +08:00
parent 87731a6379
commit 78bc2c34a0
7 changed files with 1353 additions and 1293 deletions

View File

@@ -1,75 +1,8 @@
{
"index": {
"trustedBy": "Trusted by over {count} users worldwide",
"heroDescription": "Technology Meets Imagination.",
"capabilities": {
"title": "Our Capabilities",
"features": [
{
"title": "Custom Website Development",
"description": "Tailored websites and backend systems built with modern frameworks like Nuxt and Next, delivering performance, scalability, and visual impact."
},
{
"title": "Software & Tool Engineering",
"description": "Custom-built applications, internal dashboards, and automation tools that streamline workflows and enhance productivity."
},
{
"title": "Game Design & Development",
"description": "From Game Jam prototypes to commercial releases — we design and develop immersive, creative, and technically robust gaming experiences."
},
{
"title": "Interactive Media & Event Systems",
"description": "Creating dynamic, large-screen visuals and real-time interactive systems for events, exhibitions, and banquets."
},
{
"title": "Tech Exploration & Evaluation",
"description": "Experimenting with emerging technologies and evaluating software and hardware to stay ahead of the innovation curve."
},
{
"title": "Creative Consulting & Digital Strategy",
"description": "Providing expert guidance on product architecture, digital transformation, and long-term technology strategy for brands and startups."
}
]
},
"techStack": {
"title": "Tech Stacks"
},
"featuredProjects": {
"title": "Featured Projects",
"viewDemo": "Visit Site"
},
"whyChooseUs": {
"title": "Why Choose Us",
"subtitle": "We dont just build code — we craft digital experiences.",
"features": [
{
"title": "Fully Custom-Built",
"description": "Every website, system, and game is built from scratch to match your unique brand identity and performance needs."
},
{
"title": "Tech-Driven, Not Just Design",
"description": "Our engineers lead every project, optimizing architecture, performance, and security at every level."
},
{
"title": "Cross-Domain Expertise",
"description": "From web systems to games and interactive tools — we merge creativity and engineering to deliver seamless experiences."
},
{
"title": "End-to-End Service",
"description": "From concept, prototyping, and frontend to deployment and long-term support — we handle everything in-house."
},
{
"title": "Proven Project Value",
"description": "Weve delivered projects for educational institutions, brands, and game developers — with real impact and measurable value."
},
{
"title": "Future-Oriented",
"description": "Beyond client work, were building our own products and experiments, pushing the boundaries of whats possible."
}
]
},
"seo": {
"title": "Homepage"
}
}
}