How I made a Product of the Day in six lines of JavaScript

Miloslav Voloskov on April 11, 2019

TL;DR: Focus on your task. It matters the most, more than any tools ever will. I’ve recently built and published The Code of Conduct Generator t... [Read Full]
markdown guide

What are those maximalist slogans about "you dont need this and that for building great PROJECTS"? The simpliest html-template page with a pinch of JavaScript is obviously the greatest example for such a statement.

Your TL;DR is not how you ended the article.

Sloan, the sloth mascot Comment marked as low quality/non-constructive by the community View code of conduct

Been to your GitHub. Seen your portfo... ah, it doesn't work at all.

You appreciate CSSSR? Wanna work there? Or already work there? Well, I flipped them off when they wanted me. Excuse me, but even though I can understand what you feel like, I don't think we are the same ideologically. You probably store the commercial production code at public GitHub repos, because why bother? With that being said, I'm not discussing ideas with you.

I'm sorry.


Wow, dude. Don't be that easy triggered for internet has other opinions people. Take it easy. :)

P.S. I am honored that my repository has received your attention. But your conclusions are all wrong. :)

Sloan, the sloth mascot Comment marked as low quality/non-constructive by the community View code of conduct

Are they tho? Your portfolio still renders a white page with some console errors.

There are really simple projects that are really useful. Flappy Bird. Hacker News. Code of Conduct Generator – you name it.

But then there are some projects that despite being built on top-tier VPS with Symphony, loads of business logic, a complex UI that take solid three minutes to build, are completely useless. But someone like you or any of those outsourcing companies I deny on daily basis swear by them like it's the only way to build things. I mean wait, what does it mean we shouldn't use react? It's an industry standard!

I find this behavior absolutely unacceptable.

Iamdevloper, the great account you're following, said this:

10 lines of code = 10 issues.
500 lines of code = "looks fine."

And it's just what your behavior is like.


Hey Miloslav,

Thanks for the inspiring words. I completely agree with you. I teach Javascript now a days and I feel like it's become so hard to teach / learn about the basics of programming and logical thinking with all this noise and hype about the newest tools to use. Yes, tools can be useful, but nothing replaces solving a problem in a logical and efficient manner.

Would you mind also sharing your general thought process in and around those 2 hours of development? What inspired you to tackle this problem in particular? What were the steps you took in order to creatively solve it?


Thanks, nice to hear!

So, I was at McDonald's eating a bacon Bic Mac, thinking translating Indie Hackers CoC to Russian because Russian branch head asked me to. While decomposing IH CoC logically, I came up with an idea that I actually can write something to generate texts like this one.

So, using the pattern I always use in architectural stuff, I divided the text into two groups: the commons and the variables. I adopted the commons from dev.to CoC, removed the variables, then thought of some additional opinionated topics and by doing this made a complete list of variables.

I used the most minimalistic toolkit possible as usual. I hate using frameworks just because "everyone uses them".

After it was looking good on my machine, I purchased a domain and deployed the thing.

Product Hunt is the standard part of my product release workflow, as well as writing a dev.to article, so I quickly put together a PH preview images and wrote some presentational texts: an article, a tweet, a "larger tweet".

Then I just released it and all that remained is to watch it blasts off. Or not :) I was actually ready for any consequences, including feminists and other SJWs bashing me on twitter for my generator being able to generate a CoC that allows sexual stuff; complete abandonment and zero impact whatsoever; dev.to authorities asking me to unpublish the product because of adopted CoC.

When doing products, my mindset is "at least there'll be a great story if I fail". So I taught myself to never fear to do things like this.


Thanks for the quick and honest reply :D I mean, as a feminist and SJW I might not agree with your politics. But reading and having an insight into another person's process is always useful. And when a solution is simple and elegant, there's absolutely no fuss in adapting the variables to your own needs, politics, opinions and so forth. Which is what makes it a powerful product in my opinion.


TL;DR I disagree. You shouldn't count on a knife in a gunfight

While I agree with the TL;DR, had I took your words for it, I would have missed on a whole lot.

I disagree. Bringing a knife to a gunfight, one might say, is not a good strategy. There is a possibility you could still win, but I for one ain't got the whooping and kicking ass blood from Brus Lee.

The product and focus, whilst important, are not the only things that matter


I don't force you to build an Uber killer with plain JS hosted at GitHub pages. I only encourage you to think for yourself and not to choose tools just because cool guys said you should use this or that.


I'm saying the "Cool guys" recommend based on experience. Not everyone has the exprience to choose.

Oh, if only it were so!

Cool guys are often decided by either branding or appearance.

Facebook? Cool guys. That guy who wears ray bans and promotes graphql as a silver bullet on medium? Cool guy.

I guess you get the idea.


Nice post - TL;DR especially. Just a random thought - what if your working on product like React? 😂


Great work, Miloslav. It's simple but really effective. I've bookmarked it for later usage.

code of conduct - report abuse