Time to get MEAN!

Inspired by an assignment in which I was tasked to use the Javascript fetch method to make a request, nostalgia hit me as my instructor tried to make fetch happen. Of course, he couldn’t make fetch happen, but this lead to me to reminisce the great comedy of that of Mean Girls, which got me thinking of the MEAN stack (hence this blog post). So, to challenge myself, I thought I’d take a stab in utilizing the tools involved with the MEAN stack.

Why you gotta be MEAN?

So what is the MEAN stack? MEAN is a Javascript software stack for building dynamic websites and applications. MEAN utilizes MongoDB (NoSQL database), Express.js (Web Application framework that runs on Node), AngularJS (MVC framework, and Node.js (Server-side and networking).

There are many advantages by going MEAN. For obvious reasons, you’ll be writing in Javascript. Using one language that can translate into different functionalities is very powerful and puts less burden on having to learn multiple languages to achieve the same results. There are many more reasons why MEAN is great, and over the course of my blog posts, I hope to go in more depth for each tool to not only better understand each software tool, but broadening my skill set for the future.

You go Glen Mongo-go! But none for Gretchen Weiners!

To start my venture into MEAN. I started with M, which is MongoDB. MongoDB is an open-source database that stores data in JSON-like documents. MongoDB is very similar to Relational Databases with some unique differences. A major difference is that tables are considered collections in MongoDB and to make a data model by creating separate tables in a database, you can create one collection that encompasses multiple tables that share a relationship with one another.

MongoDB allows for the creation of tables while also inserting records with one step. Below you’ll see a few queries that you can perform in MongoDB and their MySQL equivalent. In the first example, MongoDB allows you to to insert a new record, and if the collection (table) doesn’t already exist, it’ll create one, whereas SQL requires the table to exist.

My foray into MongoDB has so far been limited due not being familiar with the other software within MEAN, but MongoDB has shown to be very FETCH and interesting, and I hope to continue learning more about being MEAN!

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.