Mayank Agarwal

Mayank Agarwal

307 Articles Published

Articles by Mayank Agarwal

Page 5 of 31

How to Create an Image Slider using HTML, CSS, and JavaScript?

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 9K+ Views

In this article, we are going to create a slider carousel using JavaScript. Along with using JS we will be also using HTML and CSS for representation and defining the basic layout. A carousel is basically a collection of images represented as a slideshow that is used for displaying the images, text, or both in a cyclic manner. A slider Carousel is a special type of carousel that is specifically used for displaying the slider on a website's main page. This slideshow runs in a landscape mode. We can use the eventListener() provided by the JavaScript functions to ...

Read More

crypto.createSign() Method in Node.js

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 404 Views

The crypto.createSign() method creates and returns a Sign object that uses the specified algorithm for generating digital signatures. You can use crypto.getHashes() to get the names of all available digest algorithms. Sign instances can also be created using signature algorithms like 'RSA-SHA256' in some cases. Syntax crypto.createSign(algorithm, [options]) Parameters The parameters are described as follows: algorithm – The algorithm name to be used while creating the sign object/instance (e.g., 'SHA256', 'RSA-SHA256'). ...

Read More

Creating a Simple Calculator using HTML, CSS, and JavaScript

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 4K+ Views

A student grade calculator is a web application that takes subject grades as input and calculates the overall percentage and letter grade. This interactive tool provides instant feedback on academic performance using HTML for structure, CSS for styling, and JavaScript for calculations. The percentage calculation formula is: Percentage = (Total Marks Scored / Total Maximum Marks) × 100 How It Works The calculator follows these steps: User enters marks for different subjects through HTML input fields JavaScript function retrieves and validates the input values ...

Read More

How to Create a Parallax Effect using HTML, CSS, and JavaScript?

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 1K+ Views

In this article, we are going to learn about parallax effects and how to create them using HTML, CSS, and JavaScript. We will be using the mouse-move event to show the parallax effect. During the parallax effect, two different images move in parallel to each other. Both the images will be working parallel and making the same transitions. The only difference will be they move in the opposite directions. Parallax effects are used for making websites better in terms of User Experience and enhancing the interactivity level of the website. We can move the foreground and the background images ...

Read More

crypto.createVerify() Method in Node.js

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 964 Views

The crypto.createVerify() method creates and returns a Verify object that uses the specified algorithm for digital signature verification. This method is essential for validating data integrity and authenticity in cryptographic operations. Syntax crypto.createVerify(algorithm, [options]) Parameters The parameters are described as below: algorithm – String that specifies the algorithm name to be used while creating the verify object/instance. You can use crypto.getHashes() to get available signing algorithms. ...

Read More

How to Create Timeline Animations using Anime.js?

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 532 Views

In this article, we are going to explore and learn about Timeline Animations. Anime.js is a lightweight JavaScript library that has a small but powerful set of APIs. It works upon the DOM attributes, CSS properties, SVG, and JavaScript objects. We can build multiple and complex animations using the Anime.js. Anime's built-in staggering system helps in making complex follow through and overlapping animations simple. It can also be used on both timings and properties. How to use Anime.js? We can import or use Anime.js in our code in the following two ways: ...

Read More

crypto.generateKeyPair() Method in Node.js

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 2K+ Views

The crypto.generateKeyPair() method generates a new asymmetric key pair of the specified type. Supported types include RSA, DSA, EC, Ed25519, Ed448, X25519, X448 and DH. The function behaves as if keyObject.export has been called on its result when a publicKeyEncoding or privateKeyEncoding is specified, otherwise the respective part of keyObject is returned. Syntax crypto.generateKeyPair(type, options, callback) Parameters The above parameters are described as below: type – It holds the string type for which keys need to be generated. Supported types are - RSA, DSA, EC, ...

Read More

How to Declare an Object with Computed Property Name in JavaScript?

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 514 Views

In JavaScript, computed property names allow you to dynamically create object properties using expressions inside square brackets. This ES6 feature provides flexibility when property names need to be determined at runtime. JavaScript Object – A JavaScript object contains key-value pairs where the key represents a property from which we can get and set the value of an object. Using Square Bracket Notation in Object Literals We can use square bracket expressions [] to create computed property names directly in object literals. In ES6, it's possible to use any expression within the brackets. Example 1 In ...

Read More

crypto.getCiphers() Method in Node.js

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 336 Views

The crypto.getCiphers() method returns an array containing names of all the supported cipher algorithms in Node.js. This method is useful for discovering what encryption algorithms are available on your system. Syntax crypto.getCiphers() Parameters This method takes no parameters as it simply returns a list of all available cipher algorithms. Return Value Returns an array of strings, where each string is the name of a supported cipher algorithm. Basic Example Here's how to get all available cipher algorithms: // Importing the crypto module const crypto = require('crypto'); // ...

Read More

How to Generate a PDF from an HTML Webpage?

Mayank Agarwal
Mayank Agarwal
Updated on 15-Mar-2026 19K+ Views

Converting HTML content to PDF is a common requirement for web applications. This allows users to save content for offline reading, generate reports, or create downloadable documents. There are two primary approaches to generate PDFs from HTML webpages: Using the browser's native print functionality Using JavaScript libraries like jsPDF Method 1: Using Browser Print Functionality This method leverages the browser's built-in print feature to create a PDF. It opens a new window with the content and triggers the print dialog. Steps: Open a ...

Read More
Showing 41–50 of 307 articles
« Prev 1 3 4 5 6 7 31 Next »
Advertisements