This project is my portfolio web application, where you can see all my projects and blog articles in Serbian.
- Next.js
- React
- TypeScript
- TailwindCSS
- Headless UI
- React Query
- GitHub GraphGL API (Octokit)
- Markdown It
Because the place where I put all my work and project is GitHub, I don't want to add content on both my portfolio website and GitHub manually. I came to the idea that I could use GitHub as a data source for my portfolio. Maybe it's not the best, but it seems practical to me. So, I found Octokit on StackOverflow.
I define API endpoints in my Next.js project that collect data from GitHub and returns object fulfilled with desirable data. To this point, I was not too fond of GraphGL, but after a while, I fell in love with it.
I fetched only pinned repository data on the index page with React Query (also used to cash data).
For Project page purposes, I implemented a hook that fetches all repositories with React Query.
Like with GitHub, I didn't want to copy or paste my articles from one place to another. Because I write my articles in Craft (MacOS note-taking application with a feature to export markdown files), I found it interesting to write code that will collect all my markdown files and make a blog with them.
NPM packages that allow me to do that are 'Markdown It, 'Grey Matter,' and, of course, 'fs' for converting files to a simple string.