Yes, this sounds like an all-too-familiar “Intro to Web Scripting” class or article, but I haven’t actually seen these more advanced scripting topics compared before, so I wanted to nail it down in print.
||Very powerul and easy to create custom object classes
||Now supported with version 5+ CLASS construct, but is comparatively less powerful and syntax is much more verbose
||More object-based, wraps core functionality in intrinsic objects like Date, Math, Number, String, and Array
||Less object-based, dumps functionality into global functions
|Optional procedure arguments:
||Not supported! (hence kludgy workarounds)
||Not supported! (yet?)
||None built-in, depends on the current object model (e.g. window.alert/prompt/confirm, or WScript.Echo/popup).
||Has powerful native Msgbox and Inputbox functions.
|Convenience tools (aka synactical sugar):
||Plenty (Explicit Conversions, Formatting, Dates, Strings)
||Easy (see convenience tools)
• Has ternary operator (e.g.
var foo= true ? 'bar' : 'grep';
||Powerful, more “nuts&bolts”
||Easy-to-learn, more common functionality built-in
||Some common tasks are much too inconvenient
||Verbose, disorganized, weak OO capabilities
Yes, of course it’s my opinion, based on experience (and frustration!) Feel free to proselytize me otherwise, but back it up!
My perspective is this: scripting languages are about convenience — quickly whipping out something that works, is readable, and is maintainable. If you want perfect academic code, or fastest performance, get another tool! For scripting languages, the less code and reference to accomplish a task, the better.
(Aside about Intellisense: it reminds me of the tabs -vs- spaces debate: I say tabs all the way. Any decent code editor should be able to display tabs how you like. Fewer characters to store/send, and less arrowing around pays for itself. And yes, a coder should be using a decent code editor!)
Finally, for entertainment, here’s a hilarious thread on the “JS-vs-VBS” subject. My favorite quote: “IF JScript was a movie, it’d be Citizen Kane, or The Shining. VBScript would be the Mariah Carey movie, or possibly ‘Sgt Pepper’s Lonely Hearts Club Band’ starring Peter Frampton and the Bee Gees.”
Update: added ternary/IIF note to chart ‘leftovers’.