Pro MERN Stack - Vasan Subramanian

Pro MERN Stack (eBook)

Full Stack Web App Development with Mongo, Express, React, and Node
eBook Download: PDF
2017 | 1st ed.
XVII, 328 Seiten
Apress (Verlag)
978-1-4842-2653-7 (ISBN)
Systemvoraussetzungen
46,99 inkl. MwSt
  • Download sofort lieferbar
  • Zahlungsarten anzeigen
Assemble the complete stack required to build a modern web app using React: MongoDB (a NoSQL database) and Express (a framework for web application servers), which runs on Node (JavaScript on the server side), complement React very nicely. This book will also cover many other tools that go into building a complete web application: React Router, React-Bootstrap, Redux, Babel, and webpack.

Though the primary focus of Pro MERN Stack is to equip you with all that is required to build a full-fledged web application, a large portion of the book will be devoted to React.

The popular MEAN (MongoDB, Express, AngularJS, Node) stack introduced Single Page Apps (SPAs) and front-end Model-View-Controller (MVC) as new and efficient paradigms. But it has its shortcomings such as lack of support for SEO friendly server-side rendering and being too prescriptive by being a framework.

Facebook's React is a technology that competes indirectly with AngularJS. It is not a full-fledged MVC framework. It is a JavaScript library for building user interfaces (in some sense the View part). Yet, it is possible to build a web app by replacing AngularJS with React - hence the term MERN stack.

What You Will Learn
  • Discover the details of React, the React Way, and how to get the maximum out of this library
  • See the basics of MongoDB, Express, and Node, enough to build a web app
  • Work with other tools complementary to React, including React-Bootstrap and React Router
  • Use the tools required to build JavaScript based SPAs 
  • Tie all the components together to build a complete web app.

Who This Book Is For
Developers and architects who have prior experience in any web app stack other than the MERN stack will find the book useful to learn about this modern stack. Prior knowledge of JavaScript, HTML, and CSS is required.


Srinivasan (Vasan) Subramanian grew up in various cities in India and decided to settle in Bengaluru where he started his career. He joined Accel in 2013.

Vasan is a technologist who has had a long career building software products and leading engineering teams. He has worked as the engineering head in Barracuda Networks and Insta Health Solutions before Accel. He is passionate about best practices in Web technologies, software processes and security. He likes to build Android apps in his spare time.

He works closely with early stage startups in the Accel portfolio, consulting, mentoring and helping them on all things tech.

Vasan studied electronics and communication at IIT Madras and holds an MBA from IIM Bangalore.



Assemble the complete stack required to build a modern web app using React: MongoDB (a NoSQL database) and Express (a framework for web application servers), which runs on Node (JavaScript on the server side), complement React very nicely. This book will also cover many other tools that go into building a complete web application: React Router, React-Bootstrap, Redux, Babel, and webpack.Though the primary focus of Pro MERN Stack is to equip you with all that is required to build a full-fledged web application, a large portion of the book will be devoted to React.The popular MEAN (MongoDB, Express, AngularJS, Node) stack introduced Single Page Apps (SPAs) and front-end Model-View-Controller (MVC) as new and efficient paradigms. But it has its shortcomings such as lack of support for SEO friendly server-side rendering and being too prescriptive by being a framework.Facebook's React is a technology that competes indirectly with AngularJS. It is not a full-fledged MVC framework. It is a JavaScript library for building user interfaces (in some sense the View part). Yet, it is possible to build a web app by replacing AngularJS with React - hence the term MERN stack.What You Will LearnDiscover the details of React, the React Way, and how to get the maximum out of this librarySee the basics of MongoDB, Express, and Node, enough to build a web appWork with other tools complementary to React, including React-Bootstrap and React RouterUse the tools required to build JavaScript based SPAs Tie all the components together to build a complete web app.Who This Book Is ForDevelopers and architects who have prior experience in any web app stack other than the MERN stack will find the book useful to learn about this modern stack. Prior knowledge of JavaScript, HTML, and CSS is required.

Vasan Subramanian has experienced all kinds of programming, from 8-bit, hand-assembled code on an 8085 to AWS Lambda. He not only loves to solve problems using software, but he also looks for the right mix of technology and processes to make a software product team most efficient. He learned software development at companies such as Corel, Wipro, and Barracuda Networks, not just as a programmer but also as a leader of teams at those companies.    Vasan studied at IIT Madras and IIM Bangalore. In his current job as CTO at Accel, he mentors startups on all things tech. While not mentoring or coding (or writing books!), Vasan runs half marathons and plays 5-a-side soccer. He can be contacted at vasan.promern@gmail.com for boquets, brickbats, or anything in-between. 

Chapter 1: Why MERNThis is an introductory chapter that discusses the history of React and MERN and why it's suitable for a variety of web apps. One interesting topic that I will be discussing here is why it was created and what problem it tried to solve. This will give great insights into what kind of apps React is most suitable for, and for what kind of apps it will be a misfit.Chapter 2: Intro to React and Hello WorldThis chapter starts with installation of some basic components: Node, npm, Express, Babel and React. Then, the first pieces of code is written, which brings up the customary Hello World app. All the code at this point is in React (ie, no server side coding). I introduce the basics of React in this chapter.Chapter 3: React ComponentsHere, I'll invent the functional requirements of our sample app that we'll use throughout the book. Then, I'll start off the first important concept of React: components and composition. Using this, we'll build the first cut of the sample app – we'll build the UI to show a list of bugs, a placeholder for a filter to control the list and another placeholder which will become a form to add a bug to the list.Chapter 4: Data from ServerIn this chapter, I will describe how data can be served from the server via APIs. I'll introduce Express and describe how to create REST APIs using Express routes. At the end of this chapter, we'll be serving the data from the server instead of hardcoded data on in our app scripts, and using this data to render our components.Chapter 5: Using MongoDB to save the dataHere, we'll take data handling to the next level and introduce MongoDB. We'll explore how to save and retrieve data from a MongoDB database via the Mongo shell, and later, via the MongoDB Driver from our app server.Chapter 6: Build and Bundle using WebpackWhen we have many components, it is good to modularize the app. It also becomes essential when we start using third party libraries. In this chapter, I show how the app can be split into modules. To manage the dependencies and create a single bundle containing all the front-end code, we will use a utility called webpack. At the end of this chapter, we have a complete stack and the required development tools all in place. Further chapters will improve our sample app by adding more features, which require other libraries and/or features of each component of the MERN stack.Chapter 7: Dynamic Components and InteractivityWe'll take Components to the next level in this chapter. I'll cover how to dynamically update components by manipulating state, how to deal with user interaction and finally how to communicate between components. At the end of this chapter, the user will be able to add a record to the list using a form.Chapter 8: Routing using React RouterRouting is the act of switching between sections of the app using a URL that indicates where we are. In a single page app (SPA) a new URL does not translate to a full page request to the server, the DOM is updated by making lightweight ajax calls. React by itself does not mandate any particular routing mechanism, but fortunately there are other libraries that simplify routing for us. In this chapter, we'll introduce React Router and use that to route between different views in the app.Chapter 9: Forms and Component LifecycleHandling user input via forms the React is a little different from the conventional Javascript / jQuery way. In this chapter we'll explore how user input is captured. We'll explore controlled components and uncontrolled components and which is one is appropriate in which situation. We'll now have proper forms acting as input to adding a new bug, editing an existing one, and setting a new filter.Chapter 10: Using React BootstrapReact Bootstrap is an epitome of how to build reusable React components. By using some existing Bootstrap components to give a polished look to our UI, we'll also learn how to build good re-usable components.Chapter 11: ReduxThe Flux architecture simplifies state handling by encapsulating all the state in what's called a Store. Instead of multiple states within each component, the Flux architectural pattern helps us think in terms of a global state. There are many implementations of Flux, we'll choose the Redux implementation and refactor the app.Chapter 12: Session handlingAny web app will need some authentication and perhaps authorization. In this chapter, I'll introduce sessions in Express, and how to connect a session to say, a Google Authentication sign-on. Now, our app will be protected by only those who we can give access. We'll also be able to restrict who can do what kind of operations in the app.Chapter 13: Server side renderingA React based app is not complete till we take advantage of server side rendering. This lets us render entire pages when required, especially for automated search engine bots such as the Google-bot. At the same time, we keep our human users happy by behaving as a single-page app when requests come from a browser.Chapter 14: Concluding remarks and mern-cliWe'll wrap up and re-cap the important concepts of the previous chapters. This is also an opportunity to introduce mern-cli, a quick way to scaffold and start off a new project.

Erscheint lt. Verlag 2.3.2017
Zusatzinfo XVII, 328 p. 31 illus. in color.
Verlagsort Berkeley
Sprache englisch
Themenwelt Mathematik / Informatik Informatik Programmiersprachen / -werkzeuge
Informatik Software Entwicklung User Interfaces (HCI)
Mathematik / Informatik Informatik Web / Internet
Schlagworte Express • Express.js • MERN • MERN Stack • mongo • MongoDB • Nodejs • react • Reactjs
ISBN-10 1-4842-2653-4 / 1484226534
ISBN-13 978-1-4842-2653-7 / 9781484226537
Haben Sie eine Frage zum Produkt?
PDFPDF (Wasserzeichen)
Größe: 3,6 MB

DRM: Digitales Wasserzeichen
Dieses eBook enthält ein digitales Wasser­zeichen und ist damit für Sie persona­lisiert. Bei einer missbräuch­lichen Weiter­gabe des eBooks an Dritte ist eine Rück­ver­folgung an die Quelle möglich.

Dateiformat: PDF (Portable Document Format)
Mit einem festen Seiten­layout eignet sich die PDF besonders für Fach­bücher mit Spalten, Tabellen und Abbild­ungen. Eine PDF kann auf fast allen Geräten ange­zeigt werden, ist aber für kleine Displays (Smart­phone, eReader) nur einge­schränkt geeignet.

Systemvoraussetzungen:
PC/Mac: Mit einem PC oder Mac können Sie dieses eBook lesen. Sie benötigen dafür einen PDF-Viewer - z.B. den Adobe Reader oder Adobe Digital Editions.
eReader: Dieses eBook kann mit (fast) allen eBook-Readern gelesen werden. Mit dem amazon-Kindle ist es aber nicht kompatibel.
Smartphone/Tablet: Egal ob Apple oder Android, dieses eBook können Sie lesen. Sie benötigen dafür einen PDF-Viewer - z.B. die kostenlose Adobe Digital Editions-App.

Buying eBooks from abroad
For tax law reasons we can sell eBooks just within Germany and Switzerland. Regrettably we cannot fulfill eBook-orders from other countries.

Mehr entdecken
aus dem Bereich
Eine praxisorientierte Einführung mit Anwendungen in Oracle, SQL …

von Edwin Schicker

eBook Download (2017)
Springer Vieweg (Verlag)
34,99
Unlock the power of deep learning for swift and enhanced results

von Giuseppe Ciaburro

eBook Download (2024)
Packt Publishing (Verlag)
35,99