Summary
Build a website to list and showcase all available templates from the npm registry.
Requirements
1. Template Listing Page
- Fetch all
@nesalia/template-* packages from npm registry
- Display template cards with:
- Template name/ID
- Short description
- Link to repository
2. Individual Template Pages (/template/[slug])
Each template should have a dedicated page showing:
-
From npm registry:
- Name and version
- Description
- README (full content)
- Repository URL
-
From GitHub API:
- Topics/labels
- Stars count
- Forks count
- Website/homepage
- Full description
3. Design
- Dark mode by default
- Responsive layout
- Clean template showcase
Technical Approach
API Routes
/api/templates → GET list of templates from npm
/template/[slug] → GET template details + README
Data Sources
| Data |
Source |
| Template list |
npm search @nesalia/template |
| Package info |
npm registry API (contains repository URL, readme) |
| GitHub data |
GitHub API (topics, stars, description, homepage) |
Implementation
- Create
/api/templates route - Fetch from npm registry
- Create
/template/[slug] dynamic route - Fetch package + GitHub data
- Build UI components - Template cards, template detail page
References
Summary
Build a website to list and showcase all available templates from the npm registry.
Requirements
1. Template Listing Page
@nesalia/template-*packages from npm registry2. Individual Template Pages (
/template/[slug])Each template should have a dedicated page showing:
From npm registry:
From GitHub API:
3. Design
Technical Approach
API Routes
Data Sources
npm search @nesalia/templatenpm registry API(contains repository URL, readme)Implementation
/api/templatesroute - Fetch from npm registry/template/[slug]dynamic route - Fetch package + GitHub dataReferences
packages/create/src/registry.ts