by jimjimjim · 10y ago · 0 comments
Half the people complained about VB being good enough and more popular.
But the overall feeling was that once the rapid application dev version is out the door and ok then it's a good time to redo it with something more engineering-y, for long term support before the first version gets too ossified.
(i'm sure i'm going to burn karma for comparing node with vb but...)
I'll take the hit for you and flat-out say that node.js is the new VB.
In fact, for those of you that have been around a while, I think we can all agree that node.js is the new PHP was the new Visual Basic, etc.
Not in the sense that they do the same things, but that they were purposely built for non-programmers (baby-devs) to be able to program (which is good!) but by the same token, invited entire (and continuing) mountains of half-assed, unsupported(unsupportable) code that just begets generations of garbage.
If you are a consultant, fixing this garbage can be a whole career.
I like Python too (as well as node,) but your characterization of node is over-broad and, imo, inaccurate.
... as an alternative to C++ and Perl. And in that respect, it is a snap to pick up. It is pretty easy, not as easy as, say, Javascript, but still easy to pick up, I agree.
Node.js is cancer. We all use it, because of the momentum it has with designers instantly being able to declare themselves "full-stack devs", but make no mistake -- Node.js and npm are an abomination that we will look back on in ten years and shudder.
I agree that it's cancerous, and that making the server side more accessible to front-end developers isn't worth all the problems Node introduces long-term. My dream is still a statically-typed version of Erlang.
Do you have a citation for that? My understanding of the timeline and Guido's writings on the subject make it seem very unlikely that C++ or Perl had any significant impact on the decision to create Python or the design of Python. Python would very likely still exist in a world without C++ or Perl, as far as I can tell.
Python isn't even in the same lineage as either of those languages, though it shares a lot of features and patterns with Perl (as there has been some cross-pollination between the communities over the years). And, Python (started in 1989) is only a couple years newer than Perl (1987) and Perl was tiny enough to likely not really even be on Guido's radar at the time.
There may be a bunch of developers who think in terms of their own evolution as coders, and when they discovered various things, and your history may have Python coming well after Perl (I know I only started using Python professionally six or seven years after I first used Perl). But, I think you're overlaying your own perception onto events and it's distorting the actual history.
This is in stark opposition to "just let me quickly do stuff, and I don't care if the resulting code is buggy and unreadable" - the VB6/PHP school of language and framework design. Which, unfortunately, seems to be a rather popular approach in the JS ecosystem, as well.
I've seen .NET (and even C) programmers that after a year of coding using node still don't have a clue what the hell is happening.
Dynamic typing vs. Static typing doesn't make a language harder. If you prefer dynamic languages you are just a bit lazier and short sighted.
Async vs. Sync (specially the way node handles it) IS harder, though.
> If you prefer dynamic languages you are just a bit lazier and short sighted.
In theory, the only drawback of a statically typed language is the up front work required to make the compiler happy. In practice, you end up losing a lot of expressive power, and abstractions that were previously effortless now either add a lot of verbosity/complexity, or are simply impossible. Scala is the most expressive statically typed language I've seen, but even there you often have to jump through hoops to implement certain abstractions in a type safe way. The decision to use a dynamic language is not about laziness.
At least that's what I recall from reading/watching the initial videos back when it was released. At the very least I've never heard the 'same language front and back' argument until later on in Node's life.
But perhaps I misremember?
I think VB is more similar to Python in the sense that both languages were designed with some sense of simplicity and straight-forwardness in mind.
Both PHP and Javascript are much more complex from a language design standpoint, which makes them more difficult to learn "well" for beginners. Yes, they are both hugely prolific because of the web, and lots of people copy/paste code around not having any clue how it works, so I won't deny your "generations of garbage" comment. But you're assessment is a little too simplistic.
A good engineer can write high quality code in "almost" any programming language. It's the coder, not the language, that determines engineering quality.
Complex in the sense that they were originally thrown together and the results of the program might best be described as "stochastic output", yeah I can agree with that.
> A good engineer can write high quality code in "almost" any programming language. It's the coder, not the language, that determines engineering quality.
Sure, but it sure seems funny that "high quality code" is nearly non-existent in PHP and javascript world ...
Absolutely, they are complex because of poor initial designs, and actually even more complex now due to all the efforts to maintain backwards compatibility...
> Sure, but it sure seems funny that "high quality code" is nearly non-existent in PHP and javascript world ...
jQuery is an incredibly well engineered library by John Resig. I think that jQuery was one of the big technological leaps forward that led to the proliferation of web applications.
For a long time, people thought that cross browser JS inconsistencies and confusing API standards meant that you couldn't build interactive UI applications in the browser. And now they are ubiquitous.
So I guess it depends on your definition of "high quality code". I don't think quality code is about some arbitrary coding aesthetic. It's about results, and it's about what your code does, and how it creates value.
PHP code is a breeze to work with using composer, and most packages use namespaces and have great intellisense. But good luck doing anything concurrently.
NodeJS is fast, and boy can it handle a lot of tasks at once using the event loop! But I can't for the life of me figure out modules or get good intellisense.
There's plenty of high quality code in each. I'd just never write a complex app in either.
That's just a platitude, and it's wrong.
Languages with better features allow engineers at varying levels of experience to write better code than they otherwise might.
JS almost forces you to write garbage.
There are ways to work around this...
First, ES6 brings a lot of enhancements to JS. However, it also makes JS even more complex and unwieldy because now you have all of these new and old language features co-existing.
If you use a tool like ESLint, you can limit yourself to a subset of the whole ES6 standard that I think is a decent programming language.
There's also other ways to go at it, by using a language that compiles to JS like TypeScript, however maybe that would be considered cheating in the context of this argument.
It didn't even have a regular syntax for the sake of backwards compatibility. For example, Line was a method on Form (kinda eh, but okay); but you couldn't actually invoke it as you'd normally invoke a method. It had to look like the LINE statement did in BASIC circa 70s:
form.Line (1, 1) - (100, 100), vbRed
Note that parentheses here are not some kind of tuple syntax. Instead, they're a part of the special Line syntax, as well as the dash between. On the other hand, vbRed is just a named constant.But wait, it gets better. Say, you want to draw a filled rectangle. Well, a rectangle is also defined by two points, so BASIC has historically used the LINE statement for that as well, and VB follows suit:
form.Line (1, 1) - (100, 100), vbRed, BF
Unlike vbRed, BF here is not a variable name - it's more special syntax. "B" stands for "block", and "F" stands for "fill" (so you can do "B" without "F").Note that you can have a variable named BF. And if you do something like, say:
form.Line (1, 1) - (100, 100), BF
That is legal, and uses the value of that variable as the color of the line (instead of drawing a rectangle, as you might have expected). And it'll probably work, too, regardless of the type of "BF", because VB tries incredibly hard to implicitly convert something to something else when types don't match.Note that all of this is part of the language syntax, not the library. The actual function just takes a bunch of arguments, same as any other; but the language then piles all this useless syntactic syrup on top of that.
This is just one tiny corner of the language, and not even the most headache-inducing one - you hit it once, you read the manual, and mostly that's that. But then there's stuff like default properties and the Let/Set distinction:
Let x = y
Set x = y
In VB, these two statements are both assignments, but what they assign to is different. And you actually have to know and understand the difference, because there isn't just one assignment syntax that does the right thing for everything - some types only work with Let, and some types must be assigned with Set to get what you want....hopefully that quiets down the nonsense :)
Isn't it possible to say this for just about every programming language?
But C++, Java, Perl, even Python has a bit of a learning curve that demands some small amount of commitment (and more importantly, understanding) to get moving with.
Javascript, VB, PHP can get a person creating things in an afternoon (which I am not against, I like that it might inspire people to get into "real" development), which invites hit-and-run development.
The lower the barrier to entry, the more "inexperienced" people you get
And with nodejs the inmates are running the asylum
There is great nodejs code, for sure. But as left pad has shown us, it seems it is a big "Neverland"
outside of internety places, big iron and academia, that was it. 'must be compatible with windows' started appearing in 'request for proposal' specs.
what microsoft pushed got massive mind share.
I can definitely see prototyping something in whatever language is convenient and after proving its usefulness rewrite it in a language that fits wider goals. Their motivation[1] seems pretty solid.