Posts

Showing posts from June, 2020

JavaScript Array methods introduced in ECMAScript 1

Image
JavaScript Array methods introduced in ECMAScript 1 Array.concat() The concat() method is used to join two or more arrays. This method does not change the existing arrays, but returns a new array with contains the value of merged arrays. Syntax: const new_array = array_1.concat(array_2, array_3, ..., array_n); Example: const one = ["a", "b"]; const two = ["c", "d"]; const three = ["e", "f"]; const result = one.concat(two, three); console.log(result); // Output: ["a", "b", "c", "d", "e", "f"] Array.join() The join() methods create a new string by concatenating all of the elements of in an array. The elements in the array will be separated by separator. The default separator is comma(,). This method does not change the original array. Syntax: const str = array.join(separator); Example: const nameArray = ["p", "r", "a

10 NodeJS Tips and Tricks for developers

Image
10 NodeJS Tips and Tricks for developers NodeJS is an open-source server side runtime environment built on Chrome's V8 JavaScript engine. It provides an event driven, non-blocking (asynchronous) I/O and cross-platform runtime environment for building highly scale-able server-side applications using JavaScript. Node offers many benefits including Low Memory Usage, Good Performance and Large Ecosystem of Packages currently numbering about 475000. 10 Tips to working in NodeJS 1. Use NPM packages To avoid reinventing the wheel use existing NPM packages when they are plug-able to your project. Below is the list of top 15 NPM packages used by developers. 1. React JS 2. Prop-types 3. Moment 4. Express 5. Request 6. Lodash 7. Async 8. Chalk 9. Commander 11. Debug 12. PM2 13. Mocha 14. Passport 15. Nodemailer 16. Mongoose 2. Use NPMS.IO to find packages To search NPM packages use NPMS.IO instead of using NPMJS.COM . npms.io is a replacement to the official npm

What is Deno and will it Replace NodeJS?

Image
What is Deno and will it Replace NodeJS? What is Deno? Deno is simple, modern and secure runtime for JavaScript and TypeScript , created by Ryan Dahl - the original creator of Node.js. The project is intended to fix design problems in Node.js described in Dahl's famous talk "10 Things I Regret About Node.js". 10 Things I Regret About Node. js — Ryan Dahl Not sticking with Promises He added promises to Node in June 2009 but removed them in February 2010 for minimal. It’s possible unified usage of promise in Node would have sped the delivery of the standardization and async/await. Security Node program can access all the system calls, such as writing to the disk, accessing to the network. The Build System (GYP) If you are writing a module links to a C library, you’d use GYP to compile that C library and link it into Node. Chrome used to use GYB, but now Node is the sole GYP user. Funky interface, it’s Python adaptation of JSON. Node has several unn

Top 5 Programming Languages to Learn in 2020

Image
Top 5 Programming Languages to Learn in 2020 The programming and developer communities are emerging at a rate faster than ever before. Various new programming languages are coming up that are suited for different categories of developers (beginners, intermediate, and experts) as well as for different use cases (web application, mobile applications, game development, distributed system, etc). Every beginner is puzzled with the question, "What programming language should I learn?" Let us take a look at best Programming Languages to learn in 2020 for a job and for future prospects: Why the top programming languages are so popular? We will take a look at five of the most popular programming languages to learn and why people love them. If you are starting your programming career in 2020 or if you want to learn your first or second programming language, then it is wise to learn one of the mainstream and established programming languages.  Worldwide Pro