Dave's Notebook

JavaScript Fatigue Makes Me Scream

Maybe JavaScript Fatigue makes you scream too.

Are you annoyed with the constantly changing JavaScript environment?  Do you wish things could just settle down for a bit?  Have you decided that you won’t learn anything new because there will just be something new to learn tomorrow?

Welcome to JavaScript Fatigue.

But frankly, unlike many people who talk about JavaScript Fatigue, I see JavaScript Fatigue and the much broader subject of language fatigue as a symptom of a much larger problem that has less to do with JavaScript and more to do with human psychology and the state of the programming community at large. image

What is JavaScript Fatigue

JavaScript Fatigue is the belief that there are so many ways of assembling a JavaScript project that instead of just having to learn JavaScript, you have to learn several other related technologies. It is in essence, more about decision overload than it is about JavaScript specifically.

Think about the average JavaScript project that goes beyond the (now) old school “Augment my form with some jQuery.”

Here are a sample of decisions that need to be made:

  • Should you use a JavaScript framework, or just write native JavaScript?
  • If you decide to use a framework, which one should you use?
  • What tool(s) will you use to bundle, minify, cache bust, and tree shake your code?
  • Should you bother lazy loading?
  • Will you use MVVM, MVC, Redux or something else as a basic architecture?
  • How do you plan on dealing with AJAX calls? Callback hell? Promises? RxJS? Something yet to be created?
  • What directory structure will you use?
  • What component libraries will you use?
  • How will you style your application? Raw CSS? Bootstrap? Material Design?
  • What development environment will you use?
  • Oh and by the way, to use most of these tools you’ll need to learn node and may need to decide between NPM and YARN.

I recently heard that for a basic React application there are about 40 different decisions of this kind that need to be made.

Why JavaScript Fatigue Is Considered a Problem

If you are working on your own, or working in a small shop without any clear architectural direction, the choices can seem overwhelming.

For that matter, if you are an architect, this is still a pretty long list of things that you need to learn well enough to evaluate.

But the reason JavaScript fatigue is a problem is because it triggers emotions of fear, anger, and depression.

It all starts with fear. You look at all the stuff that you “need to learn” and think, “I can’t possibly learn all of that. And even if I do, there will be something newer tomorrow that I’ll need to learn.”

And so your fear turns to anger. I’m not talking rage kind of anger. Just that mild, “I’m not in control here and I’m feeling a bit uncomfortable” kind of anger. And this point, the next most logical thing most of us attempt to do is to try to get some sort of control over the situation. But in this case, the beast can’t be tamed. So, we resign ourselves to the situation and decide that since we can’t control any of it, we’ll give it a name and in really extreme situations give up learning any of it.

Yes, I’ve actually read comments and had conversations with people who have told me as much. “Too much new stuff to keep track of, I’ve just given up.”

Hey, OK. 

Don’t complain to me when you can’t get a job though.

How to Fix JavaScript Fatigue

I used to think that the people who had given up like this had either lost their love of learning, or were so distracted by the bright and shiny that they had hit overload and couldn’t continue. I now see that the real problem is depression. A natural extension of anger.

But, suppose there was a different way of looking at all this JavaScript Fatigue stuff?

Yes, there is a lot of stuff to learn. A lot of stuff you could learn. And you see, that’s the first step. There is a world of difference from NEEDing to learn all that is out there and having that all be things you could learn.

I doubt you evaluated all the possible languages you could use prior to using the first language you used. Maybe it was chosen for you by your first job. Maybe it was the language you were most attracted to. In my case, I tried three different languages prior to my first job and when I started my first job, I wasn’t using any of them.

Even today. How many languages are there? How many do you know?

The point is, you don’t HAVE to know everything about anything. You really only need to know enough to get your work done. Sure, there will be something new and shiny. Take your time and evaluate if it is even worth looking at. Dip your toes in. Does what you’ve seen so far make sense? Go further.

Recently, YARN has become the “hot new thing.” I tried it. It didn’t work in my current environment. At least for now, we are sticking with NPM. We’ll take another look when it matures a bit further.

I love learning. But, I also realize I can only learn one thing at a time. I can’t be awesome at everything. So, I focus. Everything else I might need to know, I learn well enough to get the core thing done.

Conclusion

And so, the cure for JavaScript Fatigue lies not outside of us, but within. Fix your perspective. Focus on what you need to know now. Learn bits at a time. Don’t worry about what is coming. There will always be new stuff. Not just with JavaScript but in the programming world in general. Even in the world at large.

Don’t worry, be happy!