JavaScript (JS) Programming

-
What are Callback Functions in JavaScript?
If you’re a programmer, you’ve probably heard of functions, which are a set of statements that perform an action and return an output but what are callback functions?
The callback function is an extremely important concept of javascript and is widely used in promises, event listeners, arrays, and much more.
We’ll go over what callback functions are and how to use them in JavaScript in this tutorial as well as We will also talk about the synchronous and asynchronous callback functions. To have clear and profound concepts of Callback functions we will implement some examples as well.
-
What Does the “use strict” Directive Do in JavaScript
JavaScript evolved for a long time having no compatibility issues and modified by adding new features but not changing the old features. It had its advantages and disadvantages and the advantage was that it didn’t allow the breaking of the existing code, however, the disadvantage was that any error made by the developers or creators was stuck within JavaScript forever.
It carried on until ECMAScript 5 (also referred to as ES5) was introduced in 2009 whose perk was that it added new features while modifying current ones. However, by default in JavaScript, these modifications are off. One needs to enable it with a special message or command which is the “use strict”.
-
Top 10 Popular Websites Built using JavaScript – Examples
Popularity of JavaScript is increasing day by day with it’s usage for building websites, mobile applications, web based games and server side applications. It’s a client side scripting language but with the introduction of NodeJs, it’s now possible to handle server side as well.
JavaScript is evolving everyday, making it’s way more into the tech world by introducing various frameworks, which makes the life of developers easy. Many websites which are popularly known are built around JavaScript which shows how important and useful the language is. In this write-up, you will have the top 10 popular websites built using JavaScript.
-
What are JavaScript Object Accessors
JavaScript object accessors are used to access and update the objects and two keywords used for this function are getter and the other is the setter. JavaScript introduced getters and setters in ES5 in 2009.
We’ll look at what getters and setters are and how to utilize them in JavaScript in this tutorial as well as go over why you should use get or set methods of JavaScript. Apart from this, we will discuss the object.defineProperty() as well. In the end, we will shine some light on which browser supports the set and get methods. So let’s get started.
-
How to Reverse an Array in JavaScript
Reversing an array is a very popular coding problem which is often asked as an interview question when applying for an entry level JavaScript Developer position. Sometimes you will be asked to modify the original array so that the first element becomes the last and the second element becomes the second last element of the array and so on. Sometimes you might be asked to reverse an array without changing the original array.
In this post we will look at different methods which are used to reverse an array in JavaScript; these methods will include the methods which reverse the original array as well as methods which can be used to make a new reversed array.
-
How to Speed up the Execution of JavaScript Code
When developing an app or a website, one of the most crucial elements to consider is the app’s or website’s performance. As a user, I wouldn’t want any app to take a long time to load or whenever I click something and I have to wait for some action. Often if the webpage takes 5-6 seconds to load most users including me would leave the webpage.
For web developers, JavaScript is a fantastic tool. Every web developer learned JavaScript at some point in their life. However, poor JavaScript code results in slower websites.
With this in mind, a developer always looks at ways of improving his webpage. You are in luck because today we are going to talk about how to speed up the execution of JavaScript code.
-
How to Write a JavaScript Program to Get File Extension from File Name?
The file extension is a three or four-letter abbreviation or an acronym at the end of a file that tells you what kind of file it is under different operating systems. For example, the file name is code.js hence the extension here is js. The goal of this article is to show you how to write a JavaScript program to get file extensions from a file name. We will discuss two of the easiest and most used methods to find the file extension.
-
How to Reverse a String in JavaScript
Reversing an array is a very popular coding problem that is often asked as an interview question to beginner JavaScript devs. Sometimes the interviewers add certain restrictions, forcing you to come up with ingenious solutions.
In JavaScript, a string can be reversed by many different methods. In this post we will discuss the most creative and interesting methods for reversing a string.
-
How to Link JavaScript to HTML
JavaScript is a very popular scripting language which is used both on the client-side as well as on the server-side. JavaScript is necessary for our web pages as it makes our web page interactive.
-

- Login or register to post comments
Printer-friendly version- 2485 reads
PDF version
More in Tux Machines
- Highlights
- Front Page
- Latest Headlines
- Archive
- Recent comments
- All-Time Popular Stories
- Hot Topics
- New Members
digiKam 7.7.0 is released
After three months of active maintenance and another bug triage, the digiKam team is proud to present version 7.7.0 of its open source digital photo manager. See below the list of most important features coming with this release.
|
Dilution and Misuse of the "Linux" Brand
|
Samsung, Red Hat to Work on Linux Drivers for Future Tech
The metaverse is expected to uproot system design as we know it, and Samsung is one of many hardware vendors re-imagining data center infrastructure in preparation for a parallel 3D world.
Samsung is working on new memory technologies that provide faster bandwidth inside hardware for data to travel between CPUs, storage and other computing resources. The company also announced it was partnering with Red Hat to ensure these technologies have Linux compatibility.
|
today's howtos
|








.svg_.png)
Content (where original) is available under CC-BY-SA, copyrighted by original author/s.

Recent comments
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago
1 year 11 weeks ago