8 Beginning JavaScript Developer Mistakes That Stop You from Becoming a Pro

8 Beginning JavaScript Developer Mistakes That Stop You from Becoming a Pro

Being a JavaScript developer is cool as there is a growing need for good JS programmers in the job market. Nowadays, there are a lot of frameworks, libraries, and other things that can be used in work - and to a large extent, we should be grateful for this to open source sources. But at some point, the developer starts spending too much time on JS projects compared to all other tasks.

It is very likely that this will lead to disastrous consequences for your career in the future, but you do not realize it yet. I myself have made some mistakes in the past, which are described below, and now I want to save you from them. Here are eight JS developer mistakes that could make your future not so bright.

We remind you: for all readers of "Habr" - a discount of 10 rubles when enrolling in any Skillbox course using the "Habr" promotional code.
Skillbox recommends: Educational online course "Java developer".

Using jQuery

jQuery has played a huge role in the evolution of the entire JavaScript ecosystem. Initially, JS was used to create slide shows and various kinds of widgets, image galleries for websites. jQuery eliminated cross-browser code compatibility issues by standardizing the use of abstraction layers and working with the DOM. In turn, this helped simplify AJAX and cross-browser differences issues.

However, today these problems are not as relevant as before. Most of them have been resolved through standardization - for example, this concerns fetch and API selectors.

The rest of the problems are solved by other libraries like React. The libraries provide many other features that are not available for jQuery.

With jQuery, at some point you start doing weird things like using DOM elements as current state or data, and writing terribly complex code just to figure out what's up with the previous, current, and future DOM state. , in addition to ensuring proper transition to upcoming states.

No one is stopping you from using jQuery, but take the time to learn more about the more modern alternatives - React, Vue, and Angular - and their benefits.

Avoid unit testing

I often see people ignoring unit tests for their web applications. Everything is going great - until the moment the application crashes with an β€œunexpected error”. And at this point we get a huge problem, because we lose time and money.

Yes, if the application compiles normally, without giving errors, and when compiled, it works, this does not mean that it is ready for use.

Lack of testing is more or less acceptable for small applications. But when the programs are large and complex, they are hard to maintain. Therefore, tests become an extremely important element of development. In this case, changing one component of the application will not break the other.

Start using testing immediately.

Learning Frameworks Before JavaScript

I perfectly understand those who, starting to develop a web application, immediately start using popular libraries and frameworks like React, Vue or Angular.

I used to say that you need to learn JavaScript first, and then frameworks, but now I am convinced that all this needs to be done at the same time. JS is changing very quickly, so some experience with React, Vue or Angular should be gained at the same time as learning JavaScript.

This is beginning to affect the requirements put forward to candidates for the position of developer. For example, here is what I found when I searched Indeed for the keyword β€œJavaScript”.

8 Beginning JavaScript Developer Mistakes That Stop You from Becoming a Pro

The job description says that they need knowledge of jQuery AND JavaScript. Those. for this company, both components are equally important.

Here is another description that lists only the β€œbasic” requirements:

8 Beginning JavaScript Developer Mistakes That Stop You from Becoming a Pro

And so in about half of the vacancies that I looked at. However, I believe that the correct ratio of time to learn JS and frameworks is about 65% to 35%, not 50 to 50.

Unwillingness to get acquainted with the concept of "clean code"

Every novice developer must learn to create clean code if he wants to become a professional. The concept of "clean code" is worth familiarizing yourself with at the start of your career. The sooner you start following this concept, the sooner you will get used to writing clean code right away that is easy to maintain later.

By the way, to understand the benefits of good and clean code, you do not need to try to write bad code yourself. Your skills will come in handy later, during work, when you are horrified by someone else's bad code.

Starting too early on large projects

8 Beginning JavaScript Developer Mistakes That Stop You from Becoming a Pro

At the beginning of my career, I made a big mistake: I tried to take on a big project when I was not ready for it yet.

You may ask what is wrong here. There is an answer. The thing is, if you're not a middle or a senior, then you most likely won't be able to finish your "big project". It will have too many elements and things to consider. And you won't make it if you haven't developed the habit of writing "clean code" early in your career, using tests, scalable architecture, and so on.

Let's say you still spent a lot of time on this project, did not complete it, and now you are trying to move to the middle level. And then suddenly you realize that you can’t show this code to anyone, because it’s not very good and refactoring is needed. However, you spent a lot of time on this β€œproject of the century” and now you don’t have examples of good work to add to your portfolio. And you give up one interview after another to those candidates who can show their work, albeit not very large, in a portfolio.

In any case, in the future you will have to refactor, because the code is not very good, and the technologies you used are not quite the ones you need. As a result, you understand that it is easier to rewrite everything from scratch than to try to fix it.

Of course, all this can be added to the portfolio, but a potential employer will see a lot of shortcomings there and come to disappointing conclusions for you.

Reluctance to learn data structures and algorithms

You can argue for a long time about when you need to start learning data structure and algorithms. Someone suggests doing this even before mastering JavaScript, someone after.

I believe that at the start it is not necessary to learn this in detail, but it is worth understanding the algorithms, since this will give a basic understanding of the operation of computer programs and calculations.

Algorithms are an integral part of any calculations and programs. Actually, computer programs themselves are a combination of a set of algorithms and data structured in a certain way, that's all.

Refusal of physical activity

8 Beginning JavaScript Developer Mistakes That Stop You from Becoming a Pro

It is very important for a developer to play sports. I am not a coach, but I have watched my body change year after year. Therefore, I can tell you what the lack of exercise leads to.

My first job was quite problematic for a number of reasons, and one of the problems was just that in just a year I gained almost two dozen kilograms. Then I actively studied JavaScript.

If you do not play sports, you run the risk of gaining weight, and this will have many negative consequences: obesity, migraines (including chronic ones), high blood pressure, etc. The list of problems is truly endless.

Social self-isolation

8 Beginning JavaScript Developer Mistakes That Stop You from Becoming a Pro

Family and loved ones are important. By immersing yourself in learning JavaScript and underestimating the importance of your mental and emotional life, you run the risk of sinking into depression, becoming irritable, not sleeping properly, and much more.

Conclusions

I hope some of this is useful to you. If you take care of yourself today, you won't have to correct mistakes later.

Skillbox recommends:

Source: habr.com

Add a comment