Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Full-Stack React Projects

You're reading from   Full-Stack React Projects Modern web development using React 16, Node, Express, and MongoDB

Arrow left icon
Product type Paperback
Published in May 2018
Publisher Packt
ISBN-13 9781788835534
Length 470 pages
Edition 1st Edition
Tools
Arrow right icon
Author (1):
Arrow left icon
Shama Hoque Shama Hoque
Author Profile Icon Shama Hoque
Shama Hoque
Arrow right icon
View More author details
Toc

Table of Contents (19) Chapters Close

Title Page
Copyright and Credits
Packt Upsell
Contributors
Preface
1. Unleashing React Applications with MERN FREE CHAPTER 2. Preparing the Development Environment 3. Building a Backend with MongoDB, Express, and Node 4. Adding a React Frontend to Complete MERN 5. Starting with a Simple Social Media Application 6. Exercising New MERN Skills with an Online Marketplace 7. Extending the Marketplace for Orders and Payments 8. Building a Media Streaming Application 9. Customizing the Media Player and Improving SEO 10. Developing a Web-Based VR Game 11. Making the VR Game Dynamic Using MERN 12. Following Best Practices and Developing MERN Further 1. Other Books You May Enjoy Index

Separation of concerns with modularity


While building out the MERN stack applications, we followed a common folder structure across each application, which divided and grouped the code based on relevance and common functionality. The idea behind creating these smaller and distinct sections in the code is to make sure each section addresses a separate concern, so individual sections can be reused, as well as developed and updated independently.

Revisiting the application folder structure

More specifically, in the application folder structure, we kept the client-side and server-side code separate with further subdivisions within these two sections. This gave us some freedom to design and build the frontend and backend of the application independently:

| mern_application/
  | -- client/
  | -- server/

In the client and server sections, we divided the code further into subfolders that mapped to unique functionalities, such as models, controllers, and routes in the server to a specific feature, such...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime
Visually different images