Reactive Stack: Fully reactive real-time web application

My new course, Reactive Stack: Fully reactive real-time web application is now available on Udemy.

The Reactive Stack course is intended for web developers who want to create fully reactive real-time web applications but are unhappy with the vendor lock-in that comes with some of the most popular frameworks for that task.

In this course, I will show you how to implement a real-time reactive web application using frameworks, databases and programming languages of your choice and how to easily substitute any part of your stack with another alternative without common headaches that come with such a task.

The goal of this course is to show a fully generic solution, completely independent of any language, database or framework.

Check it out and let me know how you liked it. 🙂

Victim shaming must stop!

On October 31st 2020, Politico.eu published a shameful opinion piece, titled “France’s dangerous religion of secularism”. This was the original link: https://www.politico.eu/article/france-attacks-religion-secularism-radicalism-blasphemy-islam/ which now only shows:

You can, however, still read that piece at WebArchive: https://web.archive.org/web/20201031165807/https://www.politico.eu/article/france-attacks-religion-secularism-radicalism-blasphemy-islam/
I have also captured it, just in case:

After reading this disgusting piece, I decided to write my own response to it, which I did, and then I sent it to Politico on Nov 1st 2020. At this point, I would like to emphasize that correlation does not imply causation, so my piece below may not have had anything to do with the removal of the first article. But I would still like to think that it did, even if a little.

Victim shaming must stop

Reading Farhad Khosrokhavars oppinion piece France’s dangerous religion of secularism left me with a rare sense of disgust for the future of humanity. There is so much wrong and anti-humanist in that text, than one cannot feel anything but utter anger at the obvious false pretense of care and emotion for just one group, all the while continuously shaming and blaming the victim without a shred of shame or decency.

The ridiculous nonsence starts in the very title, with the oximoronic expression “religion of secularism”, as if such a combination of words has any meaning. Yet, it is equally nonsensical as something like “islamic feminism”, or “christian science” would be. Words have meanings, and certain words simply cannot be meaningfully attached to each other.

Secularism is the absolute freedom of and, most importantly, from religion. It represents an absolute separation of church and state, and as such does not include any protection from so called “blasphemy”. On the contrary, it is a recognition of the fact that anyone can invent a religion, and thus cannot demand protection from imaginary insult of that religion. In the root of it, secularism recognizes religion for what it is: a delusion that should not be protected by law from any criticism or humor.

Secularism does not, as Mr. Khosrokhavar falsly claims, “call for respect for religions in the public space”. Secularism calls for respect of people’s right to practice their religion, so long as they do not infringe on the rights of others while doing so. The difference is staggeringly obvious.

Mr. Khosrokhavar attempts to both praise and destroy the freedom to blaspheme, by allowing for only one form of blasphemy while completely censoring another. Yet his apparent reasoning behind this attempt has nothing to do with the nature of the blasphemy, or is anything remotely resembling an objective analysis. No, His sole criteria relies on the amount of violence that results or may result from it. He actually claims, openly, that violence justifies censorship. If there was anything more antithetical to the very idea of freedom, let alone freedom of speech, I honestly cannot think of it.

“If liberty means anything at all, it means the right to tell people what they do not want to hear.” – George Orwell

I could, in a completely secular state, invent a religion of Flat-Earthism. But I cannot, and should not, demand that all globes be destroyed because, of course, they very much insult my “religious feelings”. Or to put it in Farhad Khosrokhavars words, “globes are a blasphemy that stigmatize and humiliate even the most moderate flat-earthers”.

Now, imagine if radical flat-erathers started decapitating geography teachers for insulting their religion in a geography class? I wonder how many demagogues like Farhad Khosrokhavar would condemn such acts of mindless violence, and how many would cry over “flat-earthers religious feelings”?

Would geography be labeled as, again using his words, “an extreme form of educationalism, which fuels radicalism among a marginalized minority of flat-earthers”?

Would geography be labeled as “radical educationalism”, simply for teaching observed scientific facts about reality?

Is there even such a thing as “radical educationalism”?

No.

Of course there isn’t.

Just as much as there is no such thing as “radical secularism”. Secularism, by definition, is anti-radical. Inventing meaningless oximoronical absurdities like “radical secularism” can only come from two types of people: those who have no idea what the words they use mean or those who intentionally try to deceive and incite violence among the gullible, who in turn really do not know what those words mean.

I shall refrain from any judgment on which category Mr. Farhad Khosrokhavar belongs to.

I will, however, say shame on you, in either case.

Multiple NodeJS versions on Windows

I recently got into a problem where a project I was working on was not able to use anything other than node 8, which prevented me from experimenting with any new packages. So I gave nvm-windows a try and I could not be happier. Here’s what you need to do to make it work.

First, execute npm -g list --depth=0 and write down all those global packages you want to keep. Then do the same with yarn global list.

After everything is set up with nvm, you will need to install these global packages for every version of Node you decide to use. For me, I went with 14.4.0, 12.18.1 and 8.17.0 and so I had to repeat installing these 3 times. Of course, only if you really need them in each setup, otherwise just install what you need. For me, I use yarn 1.3.2 with node 8 and yarn 1.22.4 with node 12 and 14. Again, do what you need in each setup.

Go ahead and uninstall all global packages from both npm and yarn listings you just ran. Naturally, you want to clean up yarn global packages first, since yarn is one of npm global packages 😉

Now, go ahead and uninstall node, completely. I recommend geek-uninstaller for this.

Download and install the latest nvm-windows: https://github.com/coreybutler/nvm-windows/releases

Make sure both nvm and nodejs are installed in a path without spaces 🙁

Once nvm is installed, simply execute nvm install and the specified version of nodejs will be installed. You can pick a version from the nodejs release listing: https://nodejs.org/en/download/releases/

When you have more than one version of node installed, you can always check what you have by executing nvm list:

To switch to another version, simply execute nvm use .

At this point, go thoroughly through each version you installed and add all global packages you need. Keep in mind to specify the version of the package, if that is needed. For example, I used npm -g i yarn for my node versions 12 and 14, and npm -g i [email protected] for my node version 8.

In the future, if you want to update a given version, you can use nvm install NEW_VERSION --reinstall-packages-from=OLD_VERSION, as described in this stackoverflow answer.

And that’s that 🙂

Finally, if you ever forget the nvm commands, simply execute nvm:

Clean Code – Uncle Bob / Lessons 1-6

Lesson 1

In this first lesson, Uncle Bob demonstrates the need to write a clean code and establishes the bases to achieve it, being these bases of a social and scientific nature. Making it clear that the future of programming is based on an ethical and polite code.

Lesson 2

In this second lesson, Uncle Bob teaches us the purpose of comments in the code, breaking the paradigm that commenting is something “I have to do” for the simple fact that we mistakenly consider that commenting is a good practice. For Uncle Bob, writing a comment is a sign of failure, since a good code must be able explain by itself: Fewer Comments = Better Code.

Lesson 3

In this third lesson, Uncle Bob focuses on raising awareness, given the need to increase the level of criteria in code production. Pointing to the lack of preparation in most programmers, as one of the main reasons for the inefficiency in software development today. Uncle Bob proposes a series of Expectations, through which he hopes to instill in the programmers, the knowledge and desire to prosper towards a way of programming based on ethics and responsibility.

Lesson 4

In this fourth lesson, Uncle Bob introduces us to a software development methodology oriented through testing. This is the Test-Driven Development (TDD), a practice with a long learning curve, but with significant results to generate a more robust, safer, more maintainable code and with greater development efficiency. Among other things, Uncle Bob shows us his point of view about the evolution of software to this day and its bright future.

Lesson 5

In this fifth lesson, Uncle Bob criticizes the culture of “making a disaster as quickly as possible” to generate economic gains, obtaining in the long term, exactly the opposite effect, due to a generalized lack of awareness, about the importance and purpose of a good Software Architecture. In this chapter, you will learn the fundamentals of software architecture, its rules, the value of discipline in the production of quality code, and the responsibility of disseminating the need to implement these good practices in the community of programmers.

Lesson 6

In this sixth lesson, Uncle Bob portrays us through different situations, the problem of adjusting software production time to delivery times. A divergence between the needs of the client and the commercial commitments, and the needs of the programmer to produce quality software. To solve the problem of the temporary gap between production and the deadline, Uncle Bob teaches us the basics of Agile development techniques for the optimal management of software projects.