History of JavaScript Classes

People teaching the history of JavaScript are far more common than people teaching how to write modern JavaScript. Unfortunately most if not all of those teaching history of JavaScript classes think they are teaching their students how to write JavaScript and most of the students mistakenly think that they are learning how to write JavaScript rather than that they are learning how JavaScript used to be written back when Netscape 2 through Netscape 4 were the most popular browsers.

This unfortunately means that there are lots of JavaScript beginners who have learnt (or are currently learning) to write JavaScript more appropriate to the late 1990s than it is to the 21st Century. They clearly demonstrate that they are or have taken a history of JavaScript course just by the questions that they ask which either involve commands that they are using in an inappropriate way or where the problems they are trying to resolve wouldn't exist if their JavaScript was written the modern way.

I have seen people argue that it does no harm to teach some of these obsolete ways to code at the start of the course because they are easier to understand. This would be acceptable if the alternatives were far more complicated but in almost all cases there is a better way that is not only as easy or almost as easy to use but which also avoids many of the issues associated with the obsolete code that many courses teach. Most of the other cases can be easily resolved by simply providing a half dozen lines of JavaScript code and telling the students to always use that code and that how it actually works will be covered later in the course.

Let's consider some examples of what gets taught in history of JavaScript classes and what ought to be taught instead.

If the JavaScript course you are taking teaches any of the commands that are now effectively obsolete (or which now have only very specialised uses) or fails to teach you how to avoid using global variables then your course is not teaching you how to write JavaScript, it is teaching you how JavaScript used to be written a long time ago. Taking such a course will possibly make it harder for you to learn how to write JavaScript properly as you will have lots of things you'll need to unlearn. Unfortunately many of the people actually teaching history of JavaScript courses are unaware that they are not teaching how to program in modern JavaScript as they are in need of taking a JavaScript course themselves in order to learn how they should be writing it properly and what they should be teaching. The amount of obsolete JavaScript code on the web is still growing rather than shrinking because there are still lots of people learning how to write JavaScript that is more appropriate for Netscape 2 than it is even for more recently obsolete browsers such as IE6.

If you want to know whether the course you are taking (or thinking about taking) actually teaches modern JavaScript or whether it teaches history then simply compare the course outline with the above list. It may not be possible to tell in advance from an outline as the outline may not mention any of the above items but at least the above will then give you ideas as to what to ask in order to find out what sort of JavaScript class it is. If you decide to ask the person teaching the class then don't simply ask if they are teaching modern JavaScript or history as they may not know themselves, instead use the above information to ask specific questions so as to decide for yourself if they will be teaching history.


This article written by Stephen Chapman, Felgall Pty Ltd.

go to top

FaceBook Follow
Twitter Follow