Chintan Dhokaichintanonweb.hashnode.dev·Apr 12, 2024From Concept to Code: Implementing Custom Events in JavaScriptCreating Custom Events in JavaScript: A Comprehensive Guide Introduction In the realm of JavaScript, events play a pivotal role in creating dynamic and interactive web applications. While JavaScript provides a plethora of built-in events, there are s...DiscussJavaScript
Palak Bansalpalakbansal.hashnode.dev·Apr 4, 2024DP World Frontend Interview ExperienceI recently interviewed with DP World, and here is the information I can provide. Flatten an array const arr = [1,2,[1,1,[34,67,5,1,1,1,[{a: 1}]]]]; const b = [[1,2],0,0,0,[3,[4,5]],[6,7,[[[8],9]]],10]; let newArr = []; const flatten = (arr) => { ...Discuss·4 likesfrontend-interviews
Suvesh Mozasuveshmoza.hashnode.dev·Mar 10, 2024Just In Time Compilation in JavaScriptYou may have come across this question: Is JavaScript compiled language or interpreted language? Interpreters read and execute the code line by line. Compilers translated human-readble code into machine code. Well the answer is that JS uses the b...Discuss·1 like·30 readsJavaScript
Sandeep Rajusandeepraju.hashnode.dev·Mar 7, 2024A toast to Javascript PrototypeHello Dev! In this article, we're going to learn a fascinating aspect of JavaScript called the "Prototype Chain." It's like a family tree, but for objects in JavaScript. Let's learn this concept with some simple examples first. Prototype Basics: Eve...DiscussJavaScript
ismail abu almagdcodenuggets.hashnode.dev·Feb 26, 2024What is call by value and call by reference in JavaScript?Firstly, what do you think the result of this code: var x=5; var z=x; console.log("x=" ,x , "z=",z); Simply, it's 👇: Output x=5 , z=5 If we change only the value of x, what do you think the output is? x=7; console.log("x=" ,x , "z=",z);...DiscussJavaScript
Akash Thoriyaakashthoriya.hashnode.dev·Feb 10, 2024Spread and Rest OperatorsExpert-Level Explanation In ES6, the spread operator (...) allows an iterable, such as an array, to be expanded in places where zero or more arguments (for function calls) or elements (for array literals) are expected. The rest operator (...), while ...DiscussJavaScript Fundamentals for InterviewsJavaScript
Akash Thoriyaakashthoriya.hashnode.dev·Feb 10, 2024Web WorkersExpert-Level Explanation Web Workers in JavaScript allow for running scripts in background threads, separate from the main execution thread of a web application. This helps in performing tasks that require intensive computation without blocking the u...DiscussJavaScript Fundamentals for InterviewsJavaScript
Akash Thoriyaakashthoriya.hashnode.dev·Feb 10, 2024WebSocketsExpert-Level Explanation WebSockets provide a way to establish a persistent, two-way communication channel between a client and a server over a single, long-lived connection. Unlike traditional HTTP requests that are stateless and close after a respo...DiscussJavaScript Fundamentals for InterviewsJavaScript
Akash Thoriyaakashthoriya.hashnode.dev·Feb 10, 2024Local Storage, Session StorageExpert-Level Explanation Local storage and session storage are web storage solutions for storing key-value pairs in a web browser. Local storage persists data even when the browser is closed and reopened, whereas session storage keeps data for a sing...DiscussJavaScript Fundamentals for InterviewsJavaScript
Akash Thoriyaakashthoriya.hashnode.dev·Feb 10, 2024Fetch API and AJAXExpert-Level Explanation Fetch API and AJAX (asynchronous JavaScript and XML) are used for handling asynchronous HTTP requests in JavaScript. Fetch API, a modern approach introduced in ES6, uses Promises to handle responses and provides a more powerf...DiscussJavaScript Fundamentals for InterviewsJavaScript