Book Image

Build Applications with Meteor

Book Image

Build Applications with Meteor

Overview of this book

This book starts with the basic installation and overview of the main components in Meteor. You’ll get hands-on multiple versatile applications covering a wide range of topics from adding a front-end views with the hottest rendering technology React to implementing a microservices oriented architecture.All the code is written with ES6/7 which is the latest significantly improved JavaScript language. We’ll also look at real-time data streaming, server to server data exchange, responsive styles on the front-end, full-text search functionality, and integration of many third-party libraries and APIs using npm. By the end of the book, you’ll have the skills to quickly prototype and even launch your next app idea in a matter of days.
Table of Contents (16 chapters)
Title Page
Credits
About the Author
About the Reviewer
www.PacktPub.com
Customer Feedback
Preface
8
Build a Chatbot with Facebook’s Messenger Platform

Chapter 2. Building a Shopping Cart

In this chapter, we will build a simple create, read, update, and delete (CRUD) application that will allow the user to add items to a shopping cart, remove them, update the quantity of each item, and track the total price of all added items. This is not, by any means, an e-commerce app but a brief overview of data handling with Meteor. For the frontend view layer, we will use React; also, we will take advantage of Meteor's reactive data package react-meteor-data to handle all the data changes and the dynamic rendering.

First, we will start with a very basic CRUD implementation and, moving forward, we'll refactor the app with the introduction of more concepts.

Here's what this chapter covers:

  • An overview of basic project structures and installation of the required packages
  • An overview of the application architecture
  • Inserting sample data in MongoDB
  • Implementation of a client-side routing with React-Router
  • Refactoring the app from client database edits to Meteor...