Post has attachment
Let’s learn about the most exciting thing to come to front end web layout in a long time. That is the technology of CSS Grid. CSS Grid is a brand new set of technologies that allows web designers and developers to incorporate powerful page layout techniques on the web. Traditionally, page layout of the web has been an extremely challenging practice. In the past we may have used tables, divs, layers, all kinds of CSS hacks, and ultimately CSS Frameworks like Foundation, Bootstrap, and others. Now we have CSS Grid, a very powerful two-dimensional layout tool for positioning items on web pages. You can create just about any layout you can think of with CSS Grid. Let’s take a look at some examples of how CSS Grid works now.

https://vegibit.com/css-grid-tutorial/
Commenting is disabled for this post.

Post has attachment
In this tutorial we are going to build a small project using the MEVN stack. MEVN is the acronym for MongoDB, Express, VueJS, and Node.js as the full stack application. MongoDB is our data storage mechanism, Express is the middleware to handle HTTP requests and routing, VueJS is the client side JavaScript to render data, and Node.js is the server our application will run on. As an added bonus, we’ll include a cool Bootswatch theme to make the CSS look good. Let’s get started.

https://vegibit.com/vue-js-express-tutorial/
Commenting is disabled for this post.

Post has attachment
In this tutorial we are going to build a blog powered by Node.js on the back end, Bootstrap on the front end, and MongoDB as the data store. We are going to start from scratch and build out the project one step at a time. We’ll see how to include all the packages we’ll need into Node for building the blog. Some of these include Express, Bcrypt, nodemon, express-edge, mongoose, body-parser, express-fileupload, and express-session. We’ll start with basic routes in the index.js file, and then gradually move the application into a Model View Controller architecture. Let’s get started.

https://vegibit.com/node-js-blog-tutorial/
Commenting is disabled for this post.

Post has attachment
In this tutorial we’ll take a look at creating a simple application to track stocks in a watchlist or portfolio. In order to store this data, we’ll be using MongoDB – a popular NoSQL storage solution that is often used with Node.js. We’ll see how to create the directory structure to hold this stock watchlist application, and then install MongoDB Native using npm to save it as a dependency to the package.json file. Once everything is in place, we’ll see how to connect to Mongo and insert a new stock into our watchlist. We’ll discuss a bit about the ObjectId and how it works in Mongo, and then finish up with fetching documents, counting documents, updating documents, and deleting them as well.

https://vegibit.com/node-mongodb-native/
Commenting is disabled for this post.

Post has attachment
As you build out an application, it is very easy to manually test things. You have been doing this since you started writing your first lines of code! How? Think about it. You write some code, save it, then run the code to see what the result is. Did it give you the result you wanted? Great! Then it worked. So if it is so easy to test the code you write, why write automated tests? The reason is that as your application gets bigger, it takes more and more time to manually test each part of the application.

https://vegibit.com/testing-javascript-with-jest/
Commenting is disabled for this post.

Post has attachment
Let’s now protect some endpoints by making use of JSON Web Tokens. What are JWTs? JSON web tokens are base64url encoded JSON Objects which are encrypted by the use of a private key. Embedded within the JWT can be one or more sets of name and value pairs. You might have things like a user id or user name embedded within the token. You can not see this data thanks to the encryption in place, but it can be deciphered on the server since the private key is available to the application. JWT.io has a great introduction if you would like all the details. For now, let’s see how we can use JSON web tokens to protect various endpoints in our Node API.

https://vegibit.com/json-web-token-authentication-with-node-js/
Commenting is disabled for this post.

Post has attachment
At the conclusion of our last tutorial which looks at working with Models in Mongoose, we now have a REST api which allows us to create new users and authenticate users. In a prior tutorial we also built out a restful resource for Games. In other words, we were able to create, read, update, and delete Games using the Node powered api. Now, we’ll once again go over the process of how routes files and model files work together in an express app.

https://vegibit.com/how-to-add-routes-and-models-to-node-rest-api/
Commenting is disabled for this post.

Post has attachment
In programming the Information expert, or the expert principle, is an approach used to determine where to delegate responsibilities. In other words, where should you place the code that completes specific tasks. The Information expert principle will help a developer to place the responsibility in the class with the most information required to fulfill it. In this tutorial we are going to clean up the process of generating JSON Web Tokens to make our code more clear and easier to maintain.

https://vegibit.com/information-expert-principle-applied-to-mongoose-models/
Commenting is disabled for this post.

Post has attachment
So we are going to start building the most basic of User Registration systems in Node.js using MongoDB as the data store, Express as the routing system, Joi as the validator, and of course Mongoose to make interacting with Mongo from Node easy. Below we have our sample project layout. User-Registration is the top level directory which holds the index.js file, and then we have a models directory and a routes directory. We’re going to see how to build the JavaScript files now to make this work.

https://vegibit.com/node-js-mongodb-user-registration/
Commenting is disabled for this post.

Post has attachment
NoSQL databases like MongoDB work differently than the older and more established Relational Databases like MySQL, Oracle, Microsoft SQL, and so on. Relationships in the traditional sense don’t really exist in MongoDB like they do in MySQL. In this tutorial we’ll take a look at how you can work with related data, even though it is not explicitly enforced by MongoDB. We’ll have a look at Reference Based Relationships (Normalization) as well as Embedded Documents Relationships (Denormalization).

https://vegibit.com/mongoose-relationships-tutorial/
Commenting is disabled for this post.
Wait while more posts are being loaded