JavaScript SyntaxError – Return not in function
This JavaScript exception return (or yield) not in function occurs if a return/yield statement is written outside the body of the function....
read more
JavaScript TypeError – Can’t delete non-configurable array element
This JavaScript exception can’t delete non-configurable array element that occurs if there is an attempt to short array-length, and any one of the array’s elements is non-configurable....
read more
JavaScript Error.prototype.lineNumber Property
In JavaScript, the Error.prototype.lineNumber property helps us to determine which line in our code corresponds to an error. One important thing to note is that this property is not used extensively as it is not a standard feature....
read more
Javascript Drag and Drop event – error catching
Javascript Drag and Drop event allows users to drag and drop elements within a web page. The event is initiated when the user clicks on an element and drags it to a new location....
read more
JavaScript TypeError – X.prototype.y called on incompatible type
This JavaScript exception called on incompatible target (or object)” occurs if a function (on a given object), is called with a ‘this’ corresponding to a different type other than the type expected by the function....
read more
JavaScript RangeError: BigInt divison by Zero
In JavaScript, the BigInt type was introduced to represent integers with arbitrary precision. This means that BigInt can represent very large numbers, but it also means that BigInt must follow certain mathematical rules. In particular, division by zero is mathematically undefined and impossible. Attempting to perform division by zero will result in an error in most programming languages, including JavaScript....
read more
Scope : Variable Masking in JavaScript
In this article, we will learn about Variable Masking which is also known as Variable Shadowing i.e. a variable with the same name will shadow the variable in the outer scope. When a variable is masked, the masked variable is completely inaccessible using that variable name. The scope is hierarchical thus we can enter new scope without hampering the old one....
read more
JavaScript – throw not working in an error handling situation
In this article, we will try to understand in which case or how does throw statement doesn’t work in an error handling situation and how does or by which way possible we may correct it in order to produce the correct output with the help of certain examples in JavaScript....
read more
JavaScript Error.prototype.toString() Method
The Error.prototype.toString() method is an inbuilt method in JavaScript that is used to return a string representing the specified Error object....
read more
JavaScript SyntaxError – Missing ] after element list
This JavaScript exception missing ] after element list occurs, It might be an error in array initialization syntax in code. Missing closing bracket (“]”) or a comma (“,”) also raises an error....
read more
Difference between Type Error and Reference Error in JavaScript
JavaScript is one of the most popular programming languages in the world, and it is used by millions of developers to create dynamic and interactive web applications. However, like any programming language, JavaScript is not without its quirks and pitfalls. Two common issues that developers often encounter when working with JavaScript are Type Errors and Reference Errors. While these errors may seem similar at first glance, they represent distinct types of issues in your code....
read more
JavaScript SyntaxError – Missing } after property list
This JavaScript exception missing } after property list occurs if there is a missing comma, or curly bracket in the object initializer syntax....
read more