---
title: "Discussion on \"Why do we get TypeError and ReferenceError in JavaScript?\" | Hashnode"
description: "Discussion on \"Why do we get TypeError and ReferenceError in JavaScript?\". While coding we encounter so many different types of errors. These errors often make us scratch our heads. But if we understand why we get those errors and how to solve or avoid them, then our life will become much more easier!\nIn today's blog, let's..."
url: "https://hashnode.com/posts/why-do-we-get-typeerror-and-referenceerror-in-javascript/63f0fc72c2642843847de1a3"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Why do we get TypeError and ReferenceError in JavaScript?](https://pranita.hashnode.dev/why-do-we-get-typeerror-and-referenceerror-in-javascript?utm_source=hashnode&utm_medium=feed)

While coding we encounter so many different types of errors. These errors often make us scratch our heads. But if we understand why we get those errors and how to solve or avoid them, then our life will become much more easier! In today's blog, let's...

Feb 18, 2023 · 4 min read · pranita.hashnode.dev  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)
-   [#error-tracking](https://hashnode.com/tag/error-tracking)
-   [#type-error-vs-reference-error](https://hashnode.com/tag/type-error-vs-reference-error)
-   [#webdevelopment](https://hashnode.com/tag/webdevelopment)
-   [#programming-blogs](https://hashnode.com/tag/programming-blogs)

## Written by

[Pranita Fulsundar](https://hashnode.com/@pranita)

@pranita · Pune, India

  
[View profile](https://hashnode.com/@pranita)

Developer, building useful things for web.

Hi, I’m a software engineer with a strong focus on frontend development and open-source contributions. I enjoy solving real-world problems, improving developer workflows, and building systems that scale. I believe in taking ownership of my work and paying close attention to quality and detail. I'm here to document my learnings, ideas, and practical insights from building and shipping real products. If anything here resonates with you, feel free to reach out. I’m always happy to connect and learn from others.

## Responses 2

Markdown supported · ⌘↵ to post

[SANGEETHA JULA](https://hashnode.com/@sangeetha13)

[Feb 19, 2023](https://hashnode.com/posts/why-do-we-get-typeerror-and-referenceerror-in-javascript/63f0fc72c2642843847de1a3/comment/63f1d2c10e63a77a616fef06)

Very clearly explained 🙌.

[Pranita Fulsundar](https://hashnode.com/@pranita)

[Feb 19, 2023](https://hashnode.com/posts/why-do-we-get-typeerror-and-referenceerror-in-javascript/63f0fc72c2642843847de1a3/comment/63f1d2c10e63a77a616fef06#reply-63f244a7aeb8b09284670e42)

Thanks for checking out!
