Connect to Mongodb Atlas Using Mongoose

I’m a big fan of MongoDB. One of these days, I had to deploy a MERN stack app to a shared server. It’s hard to find NoSQL database support in these shared environments. MongoDB Atlas seems like a good option in such situations. But there’s a problem. The connect options don’t list mongoose. When you select Node, it shows the MongoDB NodeJS Driver URI. What about our beloved Mongoose? We’ll just simply choose version 2....

September 29, 2022 · 1 min

Everything About JavaScript forEach() Loop Method

JavaScript forEach() method provides another way to loop an iterable object (like arrays). The forEach method uses callback functions to deal with each iteration. It uses callbacks, but that does not mean it is inherently asynchronous. Also, it can’t use JavaScript’s Break and Continue statements. Let’s jump right in. 1. JavaScript forEach - Basic Examples These examples will answer the question “how to use foreach in javascript?”. Expected results are shown as comments....

May 8, 2020 · 3 min

Java vs JavaScript - The Ultimate 2020 Comparison

Java and JavaScript are often confused to be the same by new learners. There are a few similarities and numerous differences between the two. I will be listing everything I can about Java vs JavaScript. Java vs JavaScript - 2020 Before starting to compare actual differences, let’s start with terminology. Why is the name JavaScript? JS was initially created as Mocha by Netscape’s Brendan Eich in 1995. It was inspired by Java and some other languages at the time....

April 1, 2020 · 5 min

VideoJS vs JWPlayer - Choose the Best

The default HTML5 player is very basic and depends heavily on the browser. Hence we look for better options, we’ll be looking at two of those options VideoJS and JWPlayer. Some features that your project may require are, Customizability & Extendability (plugins) Ads functionality HLS Streaming Playlists Video quality selector Subtitle functionality Social Media videos support 360 and Virtual Reality support Image preview based on progress bar hover VideoJS vs JWPlayer For me, it’s VideoJS, mostly because it allows much more control over video flow, code, tons of plugins....

March 4, 2020 · 2 min

12 Synchronous and Asynchronous JavaScript Examples

In this post, we’ll be looking at a few examples showing asynchronous and synchronous JavaScript. It’s a language of multiple flavors. Procedural & Functional Object-Oriented Asynchronous & Synchronous Structured Prototype-based Event-Driven Concurrent What is Synchronous Programming? In synchronous execution, you have to wait for the current task to finish before the next one starts. That being said, If we are talking in terms of threads, each thread can be allocated to perform a particular task....

February 18, 2020 · 5 min

MERN Stack vs Laravel - From a Developer's perspective

I’ve personally used both Laravel and MERN stack, and still have ongoing projects with both. There are many things to consider before choosing a stack to work with. For me, it boils down to the following 2 things. Do I need SEO for this project? If yes then Laravel is more favorable over MERN stack. Do I need WebSockets for some “live” functionality? then Node’s the obvious winner. Now don’t get me wrong, Laravel can do live stuff (called broadcasting) and MERN stack can be optimized for search engines, but is it recommended?...

February 15, 2020 · 6 min

React Social Login Tutorial: Google, Facebook & Twitter OAuth2

All social media giants like Facebook, Google and Twitter have tons of user data. It’s convenient for users to just ‘Continue with Google’ rather than entering all their details. It’s also great for developers because we don’t have to do the weird “email verification” thing. How do we implement the “Social Logins” feature in react? Well, that’s what this article is all about. I just want to let you know that this tutorial is for React (frontend) only....

January 24, 2020 · 5 min

Axios vs Fetch - What to use in 2020?

It’s 2020 and fetch has come a long way. Axios is still recommended, and for good reasons. There are many reasons to call Axios the obvious winner when it comes to business. Fetch API is also improving everyday, but it still lacks some awesome features. Here is an overview of what this article is going to be about. Axios vs Fetch We’ll be comparing both Axios and Fetch in an interesting way....

January 23, 2020 · 2 min