Posts for Javascript

How to copy file in NodeJS

In this article, you are going to learn about how to copy a file in NodeJS. NodeJS is an open-source JavaScript runtime built on the Chrome V8 engine for executing JavaScript code on the server-side. It is very fast and highly scalable with extensive large community support. You may perform different actions with the help of […]

January 17, 2022 in Code examples & Node
Deven
Deven wrote

What is void(0) in JavaScript

In this article, you are going to learn about how to use void(0) in JavaScript. In a normal sense, the word void refers to completely empty or blank. When it is used in programming languages, like JavaScript the word void(0) refers as it returns nothing. This operator is mostly used with the hyperlink. We use […]

January 15, 2022 in Code examples & Javascript
Deven
Deven wrote

How to add an object key dynamically in JavaScript

In this article, you will learn about how to add an Object key dynamically in JavaScipt. JavaScript is the most popular language at this moment and you can do a lot more things by using JavaScript. The main reason because of its popularity is that it can be used both in front-end and back-end. JavaScript […]

January 15, 2022 in Code examples & Javascript
Deven
Deven wrote

How to use Mongoose virtual property

In this article, you are going to learn about how to use mongoose virtual property. In mongoose, you can use the virtual property. This will let you work logically on your project. The main benefit of using the virtual property is that it will not persist the document in the MongoDB database. That means you […]

January 15, 2022 in Code examples
Deven
Deven wrote

How to convert HTML text to PDF in JavaScript

In this article, you will learn about how to convert HTML text to PDF by using JavaScript.Converting an HTML file into PDF is a very useful thing to do and you may save a bulk amount of data into a pdf file easily. In JavaScript, you may convert your HTML file into PDF and to […]

January 13, 2022 in Code examples & Javascript
Deven
Deven wrote

How to create and save schema array of strings in Mongoose

In this article, you will learn about how to create and save a schema array of strings in Mongoose. Mongoose is an ODM(Object Data Modeling) library for MongoDB and it lets you create a schema model and save documents in MongoDB. In the Mongoose schema model, you can create an array of strings. To create […]

January 13, 2022 in Code examples & Node
Deven
Deven wrote

How to query in Mongoose

In this article, you are going to learn about how to query in Mongoose. Mongoose is an ODM(Object Data Modeling) library for MongoDB that is based on NodeJS. You can create Schema, manage documents, and many more by using Mongoose. Moreover, you can query specific data. Here, query refers to the term as finding data […]

January 11, 2022 in Code examples
Deven
Deven wrote

How to convert byte array to string in Golang

In this article, you will learn about how to convert a byte array to a string in the Go language. In Go language, strings are nothing but a combination of an array of bytes. You can convert a string into a bytes array, similarly, you can convert a byte array into a string. In this […]

January 8, 2022 in Code examples
Deven
Deven wrote

What is the best way to declare global variable in VueJS

In this article, you will learn about how to declare global variables in VueJs. While working with VueJS, you need to declare a global variable so that you can access it from anywhere in the project. This is quite useful to declare a global variable otherwise you need to declare it from each file where […]

December 28, 2021 in Code examples & Vue
Deven
Deven wrote

How to convert HTML table data to excel in JavaScript

In this article, you will learn about how to convert HTML table data to excel in JavaScript. In JavaScript, you can do lots of interesting things. Converting HTML table data into excel is one of them. It is very useful and most of the time it is done by using the server-side method. But JavaScript […]

December 24, 2021 in Code examples
Deven
Deven wrote

Learn How to push an element to array in Mongoose

In this article, you are going to learn about how to push an element to an array in the Mongoose. An array is the most common data structure in all programming languages. You can store multiple data into the array. In databases like mongoose, arrays are widely used. You can store an array of strings, […]

December 14, 2021 in Code examples & Javascript