I want to learn another programming language now that I’ve been using Python for over 2 years now. I am kind of leaning on learning JS so that I can use it for the backend and also for the frontend. But the syntax is kind of weird. I heard Go is pretty good for the backend and also is compiled. What do y’all say? I also welcome other language recommendations.

13 points

If you wanted to do both front and backend development TypeScript + JS/Node would make the most sense, no? I say this as someone who works with and enjoys working with Go almost every day, but there’s only so much time to learn new stuff.

permalink
report
reply
2 points

I mean, I heard that new software engineers are allowed to work on the frontend first before the backend. So if I learnt JS now, I could master it, which would help me in the long run. Am I wrong?

permalink
report
parent
reply
6 points

Entirely depends on your skillset and company. That might be true somewhere, but seems strange.

I do recommend you pick up typescript though. It will forcibly teach you some good habits, expectations, and some more base understanding of what you’re actually doing.

permalink
report
parent
reply
2 points
*

Yeah, I was thinking of using TS anyways. I saw some video that showed how weird JS handles stuff when you try to add two things and such. I also want to make it a habit to type everything anyways. By the way, do I have to learn some more stuff if I want to use TS or is it just that it forces you to use types?

permalink
report
parent
reply
1 point

I personally don’t like anything JS related. I would simply recommend Go, but even that is not really my go-to. I found learning Nim quite entertaining, and it’s middle -ground between Pyhton and Go, which can also target JS, if you want to.

permalink
report
reply
-2 points

@tuto193 How about Common Lisp?

permalink
report
parent
reply
1 point

You can try C# and see if you like it. You can do frontend in it as well, but C# isn’t as popular on frontend as JS, so it will be harder to get a job as frontend dev. But on the backend C#/.NET is the best choice for me.

permalink
report
reply
18 points

Go has a much cleaner syntax, and is better suited to its specific niche which is (relatively) low-level BE development. If you are attracted to that niche then Go is an excellent option. Also, Go is almost a default for developing for K8S, which might be another plus.

On the other hand, JS is a more general-use language. It has a very loosey-goosey syntax and lots of weird behaviors. It is applicable on both FE and BE but be aware that in each of those, knowing JS is just a first step, since (for example) for FE development you will also need to know at least one of the major frameworks (React, Vue, Angular etc) as well as the page object model and a ton of other stuff.

Bottom line- usually the language is the tool, not the objective. Figure out what you want to develop, then choose the optimal language to do it with.

permalink
report
reply
22 points
*

JS will be far more versatile if you learn it well. It’s in so many dang things.

The biggest annoyances about JS are some things that exist in Python, so you’ll already be familiar with loosely typed systems and mutatable objects (dictionaries/hashes or what ever Python calls 'em).

Other than that, it’s mostly that there are a million ways to get the same things done, even something like, “define a class with static and instance-bound functions and properties”. Older JS techniques only use scope and the prototype and look like a gross hack. Modern JS has actual class syntax.

It all stems from the constant enhancement of the language. Many, many nice features like proper class syntax and first class modules (no more third party module syntax) came in ES2015, and a sadly small number of front end devs to this day really know them well.

Many web dev tutorials use older style techniques just because they’ve been around ages. If you learn how the new features are mostly syntax sugar on old styles, you’ll be a JS pro in no time.

permalink
report
reply
2 points

I see. Do you perhaps have a tutorial that does use those new features?

permalink
report
parent
reply
1 point

Commenting to save the answer as well

permalink
report
parent
reply
5 points
*

There’s actually a save button for those kinds of things btw.

permalink
report
parent
reply
9 points
*

This is a great answer. Bumping it as someone who got forced to move into Node/JS around 8 years ago and came to love it (after the ES2015 changes :). It’s primarily what I work in and I teach community classes on it these days.

I’ve been dabbling in Go lately for lower level server side stuff and, while I don’t dislike it, it’s a big shift in thinking. There are a lot of niceties to the Go ecosystem.

permalink
report
parent
reply

Programming

!programming@programming.dev

Create post

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person’s post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you’re posting long videos try to add in some form of tldr for those who don’t want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



Community stats

  • 3.2K

    Monthly active users

  • 1.8K

    Posts

  • 30K

    Comments