4 ms·
A lot of people seem to be saying "build a small project" and I'm not saying that doesn't work but...., but, something I've experienced a lot is that people sti
by greggman3 5y ago
A lot of people seem to be saying "build a small project" and I'm not saying that doesn't work but...., but, something I've experienced a lot is that people stick to their old ways, myself included.
As a C/C++ programmer I used to hate JavaScript (pre ES5). I didn't like it's function based scoping system. I didn't like it's prototype based class system. I loathed using it and wrote as little as possible, only enough to make a small WebGL demo or add a tiny feature to my blog. I was basically trying to use JavaScript as C/C++ and hating it.
At some point though I flipped. I actually started using JavaScript and playing to its features. I embraced prototypical inheritance and all the ways it's more flexible than class based. I embraced JavaScript's dynamic typing using, where appropriate, the ability to easy wrap APIs, to write more generic and flexible code. I also really loved closures and building functions that closed over data, something that, at the time, C/C++ didn't have.
I also really enjoyed that, at least in the browser, JavaScript is bundled with a lot of CROSS PLATFORM functionality (graphics, GPU access, audio, video, networking, UI) that pretty much no other language has and of course that I could share anything I made with just a link.
Then ES5 to current shipped with better scoping, import, map/reduce, promises, async/await
But, I bring this up because I still work with 30-40 people that, even in 2021, they work on the browser teams (Chromium, WebKit, Firefox) and yet none of them really know JavaScript. They all still have the same attitude that I had 15yrs ago. They avoid it as much as possible and they treat it like C/C++. Some of them have been doing this for 15+ years. They've written 1000s of even 10s of 1000s of lines of JavaScript to create tests for the features they're implementing but they still having really "learned the language".
- heavenlyblue 5y agoHave many front ends are actually written in vanilla JS? I thought that in many cases TypeScript is actually used instead.
- nicoburns 5y agoA lot. TypeScript is becoming popular these days, but there are still a lot more projects being written in JavaScript than TypeScript.
- chillpenguin 5y agoPerhaps it's a vocal minority or something that is giving this perception. The reality is far more projects are written in javascript than TypeSrcipt. Even greenfield projects.
- irrational 5y agoI have a similar problem, only it is with JavaScript. I started using JavaScript in 1997 and have been using it professionally since 1999. I am far more comfortable with JS pre-ES5 and tend to stick with what I know. Very very slowly I have been coming around to more modern JS, but it is very hard. It feels like complexity for the sake of complexity versus the (perhaps perceived) simplicity I have been accustomed to.
- nkozyra 5y agoI find modern JS much simpler, much more terse. You don't have to carry `this` around like a chain, you have tight arrow/rocket functions, you avoid leaky scope with var and you have mutability control. It's taken me from "this is a mess" to "ok I can work with this." It sounds to me like you have a familiarity issue. When something changes drastically in something you're comfortable with it evokes a very strong natural rejection, because it's like someone's taking something away from you.
- wizzwizz4 5y agoParts of it are overly verbose, but as a 1997 developer you're likely to understand that better. Have a play with a Lisp, or Python's functional aspects, or Haskell, then think about how you'd put those in JavaScript: chances are, you'll end up with a similar solution to what we have today.
- irrational 5y agoPerhaps that is the problem. Other developers came into JS, since that was where the jobs/money was, but wanted JS to be like the languages they left behind. Instead of adding onto JS in a “JS”-way, they pushed to change it to more closely mimic their previous languages. Now JS feels to me like this strange thing is JS at the core with these non-JS things bolted on around the edges. Syntactic sugar, like Class, that makes people coming from OOP languages feel like JS really is an OOP language like they are used to, while under the hood it is the same as always.
- chillpenguin 5y agoI agree with you for the most part. They keep adding more and more to the language and it is getting more and more bloated. It's becoming a chore to keep up with, and the added power isn't that necessary. Much of what they add is just making the language more terse. I do prefer the terseness once I get used to a new feature, but having to relearn javascript all the time is pretty annoying. I really admire small and simple languages that don't change much over time. Lisps, SML, etc. But once again, many of the improvements are quite nice once you learn them and get used to them. I wouldn't want to give up arrow functions, for example, now that I'm used to them.
- hnrj95 5y agoi agree. working on your own when learning a language seems like a great way to pick up bad habits, especially if you’re moving paradigms. eg going from c to go probably isn’t that dangerous, but moving from java to ocaml is likely quite dangerous
- rhizome 5y agoThe 30-40 people wouldn't seem to be in the market for building a small project, could they be simply happy in their jobs? Working with 30-40 C/C++ developers just for browser-oriented code you obviously work at a company of a size where people have families and stuff, settling into a career mode.
- ecshafer 5y agoI come from a C++/C/Java background and also always disliked Javascript. It still has its warts sure, but the book "Javascript the Good Parts" really opened my eyes. I liked programming lisp in school quite a bit, and the idea of just treat Javascript like a lisp and program it in this specific way was really enlightening. Prior to that I was either shoe horning it in to a java model, or building on some legacy JS that didn't really have a methodology to it.
- deleted 5y ago[deleted]
- deleted 5y ago[deleted]
- wpietri 5y agoWhat would you or others recommend to fellow dinosaurs wanting to come to grips with modern JS? The first time I learned it was back in the days when it was mainly for mouse rollovers. I want to tackle it as if it were a different language these days (which in many ways it is). But in years past I've been put off by what seemed like high volatility in the current best practices, to the point of flavor-of-the-month syndrome. I'm sure there must be a stable core that's worth learning and using, but as an outsider I have trouble spotting it.
- int_19h 5y agoOTOH there are plenty of people who do know JavaScript, and dislike it precisely because of that.