Skip to content

Instantly share code, notes, and snippets.

View nishantmendiratta's full-sized avatar
🎯
Always Curious!

That Js Dev nishantmendiratta

🎯
Always Curious!
View GitHub Profile
@nishantmendiratta
nishantmendiratta / Time To Get Back To The Basics - How Browser Reads HTML, CSS, and JavaScript.md
Last active January 7, 2024 17:24
📖 Getting Back To The Basics - How Browser Reads HTML, CSS, and JavaScript?

What happens when a browser loads a website?

  1. It fetches the HTML page (index.html)
  2. Begin parsing the HTML
  3. The parser encounters a <script> tag referencing an external script file.
  4. The browser requests the script file. Meanwhile, the parser blocks and stops parsing the other HTML on your page.
  5. After some time the script is downloaded and subsequently executed.
  6. The parser continues parsing the rest of the HTML document.

(Step 4) It causes a bad user experience. Your website basically stops loading until you've downloaded all scripts. If there's one thing that users hate it's waiting for a website to load.

@nishantmendiratta
nishantmendiratta / Made To Stick.md
Last active February 14, 2020 17:34
📝 Made To Stick

Background

At my current workplace every quarter we undergo a detailed Story Mapping Session which allows us to have a birds-eye view of the problem.

A brief introduction of Story Mapping: It is an engaging activity where all participants are involved in the process of building the product backlog on a wall, versus writing a dull 100-page requirement document.

The session is all about brainstorming and capturing requirements. However, it requires certain tools and this post is dedicated to one of the most important tools we need for this session i.e, Sticky Note.


Problem

@nishantmendiratta
nishantmendiratta / sum(1)(2)(3)(4)..( n)() Frontend Javascript Interview Question.md
Last active November 23, 2023 04:13
sum(1)(2)(3)(4)..( n)() Frontend Javascript Interview Question
Credits

Visit Akshay Saini's YT channel for full video tutorial.


Can you write code for this function: sum(a)(b)(c)....( n)(). This should return the sum of all the numbers a+b+c+..+n.


// Functions in javascripts are First Class Functions
// Functions are like objects
@nishantmendiratta
nishantmendiratta / JavaScript: Understanding the Weird Parts in 35ish minutes - Part 2.md
Last active February 3, 2020 14:19
JavaScript: Understanding the Weird Parts in 35ish minutes - Part 2/6
@nishantmendiratta
nishantmendiratta / 24 uncomfortable things which are tough-but-worthwhile.md
Last active January 22, 2020 13:52
24 uncomfortable things which are tough-but-worthwhile

I've curated here 24 hard things that could payoff forever.

Pinned this to my twitter account as well @thatjsdev

That Javascript Dev  Startups  Money   Books on Twitter   Hard things that could payoff forever  Adapt these life-changing tweaks and lead a better life  It’s not easy  but it’s worth the effort  The list has been aggregated from bu (2)


Credits

BI

@nishantmendiratta
nishantmendiratta / JavaScript: Understanding the Weird Parts in 35ish minutes - Part 1.md
Last active January 22, 2020 04:12
JavaScript: Understanding the Weird Parts in 35ish minutes - Part 1/6
@nishantmendiratta
nishantmendiratta / JavaScript: Understanding the Weird Parts in 35ish minutes - #BIGWORDS.md
Last active January 22, 2020 04:04
JavaScript: Understanding the Weird Parts in 35ish minutes - #BIGWORDS

Single Threaded

  • One command at a time (under the hood of browser maybe not)

Synchronous

  • One at a time and in order.

Invocation

  • Calling a function in js by using parentheses ()
@nishantmendiratta
nishantmendiratta / JavaScript: Understanding the Weird Parts in 35ish minutes - Introduction.md
Last active January 22, 2020 04:05
JavaScript: Understanding the Weird Parts in 35ish minutes - Introduction

If you are looking for a resource where you can learn Javascript in-depth. JavaScript: Understanding the Weird Parts Udemy course is highly recommended.

BUT

If you have a limited amount of time and want to Understand the Weird Parts of Javascript in 35ish minutes. Then tag along and read this post.

In 2015, I gathered all the learnings from the above mentioned Udemy course and created a document out of it. This document includes all the learnings which are the most important parts of Javascript. This document is quite handy and help me revise the complex Javascript concepts. I just want to give back something to the community. So, I will be sharing this document in the form of 6 posts.