How dinglevarshney12/blogghar works
Blogghar is a Next.js blog browsing and authoring frontend. Readers land on a homepage, browse or search and paginate blog listings, and open individual posts; the authoring page provides title, content-editor, and category inputs. The visible data path fetches blog collections through the blogs API, with a shared server helper also fetching that endpoint. The tree and excerpts show UI composition but do not establish persistence, publishing behavior, or backend implementation. Unsampled components are represented at their enclosing directory where appropriate.
Main entry points: explore/page.jsx Explore listings · app/page.jsx Home page · Recommend&LatestBlog.jsx Recommendations · getData.jsx Blog data helper
Components 23
Blog discovery
- Home page
app/page.jsx - Explore listings
app/explore/page.jsx - Search input
components/ui/search_input.jsx - Pagination
components/ui/pagination.jsx - Categories page
app/categories/page.jsx
Blog content
- Blog cards
components/ui/blogCard.jsx - Recommendations
components/ui/Recommend&LatestBlog.jsx - List blog card
components/ui/ListBlogCard.jsx - Blog detail
app/blog/[id]/page.jsx - Blog data helper
hooks/getData.jsx - Blogs API route
app/api/blogs/route.js
Blog authoring
- Create blog page
app/create-blog/page.jsx - Text editor
components/ui/TextEditor.jsx - Category selector
components/ui/categoriesSelection.jsx - Category definitions
constant/index.jsx
App shell
- Root layout
app/layout.js - Navigation bar
components/ui/navbar.jsx - Footer
components/ui/footer.jsx - Theme provider
lib/themeProvider.js
Shared UI
- UI primitives
components/ui - Class utilities
lib/utils.js
Other components
- Reader
- Author
Connections 28
- Reader → Home page: opens
app/page.jsx - Home page → Blogs API route: fetches blogs
app/page.jsx - Home page → Blog cards: renders
app/page.jsx - Home page → Recommendations: renders
app/page.jsx - Reader → Explore listings: browses
app/explore/page.jsx - Explore listings → Blog data helper: requests data
app/explore/page.jsx - Blog data helper → Blogs API route: fetches endpoint
hooks/getData.jsx - Explore listings → Search input: renders
app/explore/page.jsx - Search input → Explore listings: updates query
components/ui/search_input.jsx - Explore listings → Pagination: renders
app/explore/page.jsx - Explore listings → Blog cards: renders results
app/explore/page.jsx - Reader → Blog detail: opens post
app/blog/[id]/page.jsx - Blog detail → Blog data helper: requests data
app/blog/[id]/page.jsx - Blog detail → Recommendations: renders
app/blog/[id]/page.jsx - Recommendations → Blog data helper: requests data
components/ui/Recommend&LatestBlog.jsx - Recommendations → List blog card: renders
components/ui/Recommend&LatestBlog.jsx - Author → Create blog page: opens authoring
app/create-blog/page.jsx - Create blog page → Text editor: renders editor
app/create-blog/page.jsx - Create blog page → Category selector: renders selector
app/create-blog/page.jsx - Category selector → Category definitions: uses categories
components/ui/categoriesSelection.jsx - Root layout → Navigation bar: renders
app/layout.js - Root layout → Footer: renders
app/layout.js - Root layout → Theme provider: configures theme
app/layout.js - Categories page → Category definitions: uses categories
app/categories/page.jsx - Blog cards → UI primitives: uses components
components/ui/blogCard.jsx - Navigation bar → UI primitives: uses components
components/ui/navbar.jsx - Footer → UI primitives: uses components
components/ui/footer.jsx - UI primitives → Class utilities: merges classes
components/ui/button.jsx