Javascript is too weird to be a teaching language. Lexical scoping, invisible and sometimes unintuitive conversion rules, challenging runtime environments, and asynchronous code are important concepts but I wouldn't put them into an intro to programming class.
IMO the ideal programming track would be as follows:
Intro to programming track:
* Assembly --> to understand the basics of how computers work and learn simple procedural and abstraction rules.
* C --> more procedural code, more abstractions, and higher order memory management
* Java --> to learn interfaces, object oriented code, and an introduction to functional programming concepts like lambdas, pure functions, the value of immutable objects
* {Racket/LISP or Favorite functional language} --> to gain intuition with more pure functional programming
Then, I'd have separate tools track:
* web dev
* database
* embedded dev
* AI,
etc.
Then a separate theory track:
* context free languages, regular expressions, compiler design
* algorithms and data structures
* some network theory and fault tolerance results
Then I'd have a professional track:
* tools: learn source control systems, IDEs, debuggers, profilers, bug management systems, different dev systems, using Jenkins or other CIT tools.
* skills: learn about secure coding (best practices for writing auditable code with known failure modes), efficient coding (calculating big O for a given code, fixing performance bottlenecks), maintainable coding (best practices for decoupling code, writing testable code, writing unit tests)
* theory: track where you learn advanced algorithm theory, design patterns, hopefully centered around case studies.
With elective tracks for things like OS theory, networking, etc.
Too many people leave college with lots of information about data structures and algorithms but don't know how to write a unit test, how to use an IDE, how to write unit tests, how to write secure, maintainable code.