Category: Miscellaneous
-
Style Guide
A JavaScript style guide is a set of general rules that regulate how to write JavaScript code. These rules can include − which quotes to use, how many spaces to indent, the maximum line length, using single-line comments, marked with //, etc. When any company starts developing a real-time JavaScript project, 100’s of developers work…
-
Performance
JavaScript is very important in every website today. If JavaScript fails, our website wouldn’t work properly. It is important to focus on the performance on JavaScript as it has impacts on delivering a positive user experience, retaining engagement, and ensuring business success. An optimized JavaScript would ensure the pages load faster and responsive interactions contribute…
-
Debouncing
While developing the applications, sometimes it is really important to limit the function calls to improve the web application performance. Debouncing is a programming technique that helps in limiting the function calls. Lets learn more about debouncing in JavaScript. What is Debouncing? Debouncing is a simpler way to delay the execution of a particular function…
-
Canvas
Handling Canvas with JavaScript The HTML <canvas> element can be used to create and draw graphics on the web page. It can draw various graphics or shapes, like lines, circles, etc., on the web page and animate them. You can define <canvas> element in HTML, and after that, you need to use JavaScript to draw…
-
Graphics
In JavaScript, graphics can be created using the Canvas API. However, developers can also use some other libraries, like p5.js, chart.js, pllotly.js, Google charts, etc., to draw various graphics and charts. Here, we will explore some of these libraries and learn about them with help of some examples WebGL WebGL allows developers to create graphics…
-
Currying
In JavaScript, currying is a functional programming technique that is used to transform a function that takes multiple arguments into a sequence of functions that each takes a single argument. Currying is mainly used in event handling and to avoid passing the same variable as a function argument multiple times. How to achieve currying in JavaScript? There…
-
Clickjacking Attack
Clickjacking Attack An attacker employs clickjacking, a form of cyber-attack, to deceive a user into clicking on an object different from their perception; this deception may result in unintended actions. The attacker achieves this by overlaying invisible elements or frames over valid content thus camouflaging the malicious intent or manipulating the appearance of webpage elements…
-
IndexedDB
What is IndexedDB? IndexedDB, or Indexed Database, represents a low-level JavaScript API. Its function involves the storage and retrieval of voluminous structured data – this includes files and blobs. With its capabilities to work with client-side databases: it enables web applications to locally store, query, and modify data on the user’s device. This functionality proves…
-
Reference Type
JavaScript Reference Type There are two types of data types in JavaScript: primitive and reference type. Primitive data types are immutable, which means that they cannot be changed. The primitive data types in JavaScript are: Number, String, Boolean, Undefined, Null, Symbol. Reference data types are mutable, which means that they can be changed. The reference…
-
Call Stack
JavaScript engine uses the call stacks to manage the execution context. It is an important mechanism by which a JavaScript run engine keeps track of the function calls in a JavaScript code. However, the working of the JavaScript call stack is performed internally, but it is important to understand how JavaScript executes the functions. JavaScript…