Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ask me anything? #1

Open
vinitshahdeo opened this issue Apr 19, 2020 · 8 comments
Open

Ask me anything? #1

vinitshahdeo opened this issue Apr 19, 2020 · 8 comments

Comments

@vinitshahdeo
Copy link
Owner

Hello, 👋

Hope you're staying safe at home.

😷 🏠👪

  ___      _     ___  ___                  
 / _ \    | |    |  \/  |                  
/ /_\ \___| | __ | .  . | ___              
|  _  / __| |/ / | |\/| |/ _ \             
| | | \__ \   <  | |  | |  __/             
\_| |_/___/_|\_\ \_|  |_/\___|             
                                           
                                           
  ___              _   _     _             
 / _ \            | | | |   (_)            
/ /_\ \_ __  _   _| |_| |__  _ _ __   __ _ 
|  _  | '_ \| | | | __| '_ \| | '_ \ / _` |
| | | | | | | |_| | |_| | | | | | | | (_| |
\_| |_/_| |_|\__, |\__|_| |_|_|_| |_|\__, |
              __/ |                   __/ |
             |___/                   |___/ 

Feel free to shoot your doubts in this thread.

YouTube Live

Thank you so much for attending my session on Event Loops in JavaScript.


Twitter Follow

@theIYD
Copy link

theIYD commented Jul 8, 2020

Hi @vinitshahdeo ,

Thanks for conducting this event, it helped a lot in knowing the internals of JavaScript as a programming language.

I wanted to know that why is it said that JS when executed on a machine i.e Node.js does not scale as much as compiled languages do like Golang, Rust or Java ?

@vinitshahdeo
Copy link
Owner Author

Hello @theIYD 👋

Thanks for asking me this question.

Being single-threaded, Node.js has concurrency limitations but compiled languages like Go can scale up easily as they have better parallel execution mechanisms like Goroutines. But again, choice for tech-stack for your backend development between Node.js and Go totally depends upon how big your project is. In languages like Go, the parallel threads can be handled effectively.

Node.js is considered one of the best backend solutions for several reasons:

  • It inherits its asynchronous and non-blocking behaviour from JavaScript. This means that small tasks are performed in the background and don’t affect the main thread.

  • It uses the V8 engine which is considered as the fastest JavaScript engine.

  • Reusability: This is crucial for event-based applications that update data in real time, and it’s widely used for instant messaging, video chats, and online gaming.

Node.js is single-threaded, sometimes CPU-bound tasks block the event loop and slow down your program. As a result, you get a slower app, which might annoy your end-users but it totally depends how efficiently you write your Node.js application.

For larger applications, few points to keep in your mind while writing Node.js code:

  • Compile-time support: Find issues when you compile. It helps you to refactor your code.

  • Eliminate Callback Hell: Ensure that you're handling async behaviour in correct manner to avoid callback hell and increase performance.

  • Tooling: Choose best IDEs, unit-testing tools to speed up your development. npm is ❤️!

  • Logging: Getting insights into your app is critical. Integrate with third party services easily.

  • Build on well vetted frameworks: The community is awesome. There're well-popular frameworks available which is being used by millions of developers across the world.

Last but not the least, choose Node.js to read 1000 files instead calculating 10th prime number.

PS: I have never worked at scale with GoLang. My whole tech stack is JavaScript and I've shared why one should prefer Node.js over others. Peace!

@theIYD
Copy link

theIYD commented Jul 9, 2020

Thanks for the answer @vinitshahdeo ✌️

I have been working with JavaScript from last 3 years, with Node.js as the backend framework. I have been making projects which do not scale but Node.js works best for them.

My question is to get hired as a backend engineer, should i be learning Golang/Rust or any compiled language ?

@vinitshahdeo
Copy link
Owner Author

@theIYD Not really! Node.js is being used by various organizations like Postman, PayPal, Netflix, LinkedIn, etc. I believe that tech stack should not be a barrier during hiring process for <3 years of work experience.

@theIYD
Copy link

theIYD commented Jul 10, 2020

@vinitshahdeo Okay, thank you sir for clearing my doubts! 😊

@sonalipauld
Copy link

@theIYD you need not to learn new language to get hire. You need to learn how to scale with your current language. I have a suggestion here: https://twitter.com/ashokdey_/status/1281472402010943490?s=20

Also companies who hire you based on languages do not have anything to teach you for your holistic development.

@vinitshahdeo
Copy link
Owner Author

@sonalipauld Thanks for sharing the Twitter thread.

@theIYD Check out this thread for awesome views by Twitter community.

My gratitude to @ameerthehacker and @ashokdey for their thoughts on Node.js.

@ashokdey
Copy link

@theIYD you need not to learn new language to get hire. You need to learn how to scale with your current language. I have a suggestion here: https://twitter.com/ashokdey_/status/1281472402010943490?s=20

Also companies who hire you based on languages do not have anything to teach you for your holistic development.

Extremely sorry guys seem like I forgot to log out of my sister's account. 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants