DEV Community

Qiwen Yu
Qiwen Yu

Posted on

Static Site Generator - TextHTMLPress

This week, to create a static site generator is the goal. I named my generator as TextHTMLPress, and it is a command-line static site generator for generating a complete HTML web site from raw data and files. This tool is written in Python.

To write a tool like this is a challenge to me. I spent time on understanding the idea, reviewing other similar projects' source code. Pelican is one of the open source project I referred to in this project.

My school has a quite large open source community on Slack for the students to connect and communicate with each other like a professional software developer would do. I found a partner on the Slack, and his project is written in Typescript.

I found it quite interesting to work with someone who is writing the similar project as you but in a totally different way. We reviewed each other's repo on Github, and provided issues to improve our projects. I think one important thing to work with others is to check your notifications more often.

The biggest challenge to review other's code is that we wrote in different languages. I used modules in Python, and he used packages in Typescript. If we want to understand each other's code, we need to search for the proper usage for those modules and libraries. Of course, the syntax also matters. I rarely use Typescript. so when I just started to review his source code, I found it is a little bit weird for me to understand every steps.

When I was reviewing his code, I found his README file is a little bit simple for the person who has few experience with the Typescript. So I filed an issue to his repo, and to suggest him to improve his README file.
README.md Enhancement

He also filed me an issue, which is my tool has a conflict between the title and the first paragraph. My title will be treated as a paragraph. To fix this, I need to remove several lines in my code.
Title/Paragraph Conflict

After this whole process, I think the ability to review others' source code efficiently could be a really important part when doing the open source project. We need to understand others' thoughts and their way to implement the project.

I think the next step of improving my project is to make my HTML look nicer and responsive. Making proper fonts and style for the HTML.

Discussion (0)