My Account Log in

1 option

Full Stack FastAPI, React, and MongoDB : Fast-Paced Web App Development with the FARM Stack.

Ebook Central College Complete Available online

View online
Format:
Book
Author/Creator:
Aleksendrić, Marko.
Contributor:
Batra, Shrey.
Palmer, Rachelle.
Ranjan, Shubham.
Language:
English
Subjects (All):
Web applications.
Python (Computer program language).
Physical Description:
1 online resource (313 pages)
Edition:
2nd ed.
Place of Publication:
Birmingham : Packt Publishing, Limited, 2024.
Biography/History:
Aleksendric Marko: Marko Aleksendric is an analyst, a scientist, and a freelance self-taught web developer with over 20 years of experience. Marko has authored the book Modern Web Development with the FARM Stack and Mastering MongoDB 7. 0, published by Packt Publishing. With a keen interest in backend and frontend development, he has been an avid MongoDB user for the last 15 years for various web and data analytics-related projects and has built numerous Python and JavaScript web applications and tools. Batra Shrey: Shrey is the Founder of Cosmocloud, a MongoDB Champion, and a software developer by passion. As a tech startup founder building a No-Code backend with MongoDB, he combines his passion for both MongoDB and building applications at scale. Working in the industry for over 8 years, he is also an active contributor to the technical community, speaks at various world conferences and meetups, and writes his own newsletter, System Design and Architecture, which has 50K+ subscribers. He is also a distributed algorithm patent holder for his work at LinkedIn on its Search and Discovery platform. Palmer Rachelle: Rachelle Palmer is the Product Leader for Developer Database Experience and Developer Education at MongoDB, overseeing the driver client libraries, documentation, framework integrations, and MongoDB University. She has built sample applications for MongoDB in Java, PHP, Rust, Python, Node. js, and Ruby. Rachelle joined MongoDB in 2013 and was previously the Director of the Technical Services Engineering team, creating and managing the team that provided support and CloudOps to MongoDB Atlas. Ranjan Shubham: Shubham Ranjan is a Product Manager at MongoDB for Python and a core contributing member to AI initiatives at MongoDB. He is also a Python developer and has published over 700 technical articles on topics ranging from data science and ML to competitive programming. Since joining MongoDB in 2019, Shubham has held several roles, progressing from a Software Engineer to a Product Manager for multiple products.
Summary:
This book serves as a comprehensive guide for developing modern web applications using the FARM stack, which includes FastAPI, React, and MongoDB. It is designed to facilitate fast-paced web app development, offering insights into both backend and frontend technologies. The authors, experienced in the field, aim to provide readers with practical knowledge and tools to build scalable web applications. The book is intended for developers who are new to web development with Python, offering step-by-step instructions to set up databases, understand type hints, and implement REST APIs efficiently. It draws from the authors' extensive experience and community insights to prepare readers for the evolving field of web application development. Generated by AI.
Contents:
Cover
Table of Contents
Preface
Chapter 1: Web Development and the FARM Stack
Technical requirements
What is the FARM stack?
Why the FARM stack?
Why use MongoDB?
Why use FastAPI?
Python and REST APIs
The frontend - React
Why use React?
Summary
Chapter 2: Setting Up the Database with MongoDB
The structure of a MongoDB database
Documents
Supported data types in MongoDB
Collections and databases
Options to install the MongoDB database
Installing MongoDB and related tools
Installing MongoDB and Compass on Windows
Installing the MongoDB Shell (mongosh)
MongoDB Database Tools
Installing MongoDB and Compass on Linux: Ubuntu
Setting up Atlas
Creating an Atlas cluster
Getting the connection string of your Atlas Cluster
Connecting to the Atlas cluster from Compass
MongoDB querying and CRUD operations
Querying in MongoDB
Projection
Creating new documents
Updating documents
Deleting documents
Chapter 3: Python Type Hints and Pydantic
Python types
Type hinting
Implementing type hints
Advanced annotations
Pydantic
Pydantic basics
Deserialization
Model fields
Pydantic types
Pydantic fields
Serialization
Custom data validation
Model validators
Nested models
Pydantic Settings
Chapter 4: Getting Started with FastAPI
Python setup
Virtual environments
Code editors
Terminal
REST clients
Installing the necessary packages
FastAPI in a nutshell
Starlette
Asynchronous programming
Standard REST API operations
How does FastAPI speak REST?
Automatic documentation
Building a showcase API
Retrieving path and query parameters
FastAPI response customization
Summary.
Chapter 5: Setting Up a React Workflow
Creating a React app using Vite
Tailwind CSS and installation
Components and building blocks of JSX
Recap
Components
Creating dynamic components
Events and state
React Hooks with events and state
Communicating with APIs and the outside world using useEffect
Exploring React Router and other useful packages
Chapter 6: Authentication and Authorization
Understanding JSON Web Token
What is JWT?
FastAPI backend with users and dependencies
User model for authentication
Authentication and authorization with FastAPI: a walk-through
Authenticating the users in React
Persisting authentication data with localStorage
Other authentication solutions
Chapter 7: Building a Backend with FastAPI
Introducing the application
Creating an Atlas instance and a collection
Setting up the Python environment
Defining the Pydantic models
Scaffolding a FastAPI application
Creating a .env file to keep the secrets
CRUD operations
The POST handler
Handling the GET requests
Updating and deleting records
Uploading images to Cloudinary
Adding the user model
FastAPI middleware and CORS
Deployment to Render.com
Chapter 8: Building the Frontend of the Application
Creating a Vite React application
React Router
Installing and setting up React Router
React Router loaders
React Hook Form and Zod
Performing data validation with Zod
Authentication context and storing the JWT
Implementing the login functionality
Protecting routes
Creating the page for inserting new cars
Displaying single cars
Chapter 9: Third-Party Services Integration with FastAPI and Beanie.
Technical requirements
Project outline
Building the backend with FastAPI and Beanie
Introduction to the Beanie ODM
Defining the models with Beanie
Connecting to the MongoDB database
Creating the FastAPI application
Background tasks with FastAPI
Integrating OpenAI with FastAPI
Chapter 10: Web Development with Next.js 14
Introduction to Next.js
Creating a Next.js 14 project
Next.js project structure
Routing with Next.js 14
Data loading with server components
Authentication and Server Actions in Next.js
Creating protected pages
Implementing the new car page
Providing metadata
Deployment on Netlify
Pushing the changes to GitHub
Chapter 11: Useful Resources and Project Ideas
MongoDB considerations
FastAPI and Python considerations
Testing FastAPI applications
React practices
Other topics
Authentication and authorization
Data visualization and the FARM stack
Relational databases
Some project ideas to get started
Old-school portfolio website
React-admin inventory
Plotly Dash or Streamlit to create exploratory data analysis applications
A document automation pipeline
Index
Other Books You May Enjoy.
Notes:
Description based on publisher supplied metadata and other sources.
Part of the metadata in this record was created by AI, based on the text of the resource.
ISBN:
9781835886779
1835886779
OCLC:
1454588009

The Penn Libraries is committed to describing library materials using current, accurate, and responsible language. If you discover outdated or inaccurate language, please fill out this feedback form to report it and suggest alternative language.

Find

Home Release notes

My Account

Shelf Request an item Bookmarks Fines and fees Settings

Guides

Using the Find catalog Using Articles+ Using your account