Build a Frontend Web Framework (From Scratch)
- 5h 17m
- Ángel Sola Orbaiceta
- Manning Publications
- 2024
Learn how a frontend web framework works by coding your own!
Web developers use frontend frameworks every day—but do you know how these essential parts of your stack really work? Build a Frontend Web Framework (From Scratch) reveals the inner workings of web frameworks by helping you create your very own.
In Build a Frontend Web Framework (From Scratch), you’ll learn the secrets behind frameworks like React, Vue, and Angular, including:
- Create HTML documents programmatically
- Define the view with virtual DOM
- Update the HTML efficiently with reconciliation algorithms
- Create two-way communication mechanisms between components in a hierarchy
Whatever your experience level, you’ll be able to start building your framework with this guide. All you need is some core skills in HTML, CSS, and JavaScript. And once you’ve learned how frameworks function, you’ll be able to work with them more efficiently, troubleshoot bugs more effectively, and even customize them for your specific needs!
about the technology
You use frontend frameworks every day, but do you really know what’s going on behind the API? Building your own framework is a great way to learn how they interact with the DOM, generate page views, route data between components, and communicate with the underlying operating system. With this interesting and entertaining book, you’ll build your own web framework step-by-step in JavaScript, ready to share with the world as an NPM package!
about the book
Build a Frontend Web Framework (From Scratch) guides you through a simple component-based frontend framework that borrows from React, Svelte, Angular, and other familiar tools. You’ll learn how a modern framework operates by adding features like component state and lifecycle management, a virtual DOM, and reconciliation algorithms to update the HTML efficiently. You’ll appreciate how each critical concept is broken down into easy-to-digest chunks and explained with engaging graphics.
About the Author
Angel Sola Orbaiceta has worked in the software industry for over a decade, creating software for the cloud, macOS, and Windows desktop applications.
In this Book
-
About This Book
-
Are Frontend Frameworks Magic to You?
-
Vanilla JavaScript—Like in the Old Days
-
Rendering and the Virtual DOM
-
Mounting and Destroying the Virtual DOM
-
State Management and the Application's Lifecycle
-
Publishing and using Your Framework's First Version
-
The Reconciliation Algorithm: Diffing Virtual Trees
-
The Reconciliation Algorithm: Patching the DOM
-
Stateful Components
-
Component Methods
-
Subcomponents: Communication Via Props and Events
-
Keyed Lists
-
The Component Lifecycle Hooks and the Scheduler
-
Testing Asynchronous Components