A practical guide for framework developers who want to rediscover the power of the web platform
You're a developer who's been building with React, Vue, or Svelte. You've gotten comfortable with frameworks, and you might even think you need them for everything.
This book will challenge that assumption.
The Virtues of Vanilla JavaScript is a journey through building modern web applications without frameworks. You'll learn that the browser is more capable than you think, that vanilla JavaScript is more elegant than you remember, and that sometimes the best tool is no tool at all.
- React/Vue/Svelte developers who want to understand what's under the hood
- Developers who are tired of 500-dependency
node_modulesfolders - Performance-conscious engineers who need fast, lightweight applications
- Learners who want to deeply understand the web platform
- Anyone who's ever said "I need a framework for this" without questioning it
Through 10 progressive chapters with practical examples, you'll master:
- Modern DOM manipulation (it's not as scary as you think)
- State management without Redux or Vuex
- Building reusable components without JSX
- Event handling and delegation patterns
- Client-side routing without React Router
- Forms and validation using platform APIs
- Building a complete application from scratch
- Performance optimization and bundle size reduction
- When to use frameworks vs. when to go vanilla
- The Framework Detox - Questioning our assumptions about frameworks
- The DOM: A User's Guide - Modern DOM APIs are actually great
- State Management - Redux in 30 lines of code
- Components Without the Framework - Building reusable UI pieces
- Event Handling - The power of event delegation
- Client-Side Routing - No React Router needed
- Forms and Validation - HTML5 does most of the work
- Building a Real Application - Putting it all together
- Performance and Bundle Size - Why this actually matters
- Conclusion - When to use frameworks, when to go vanilla
This book isn't anti-framework. It's pro-informed-decision-making.
Frameworks are powerful tools that solve real problems. But they're not the only tools. Sometimes vanilla JavaScript is:
- Faster - 10-15x smaller bundle sizes
- Simpler - No build step, no configuration
- More stable - Code written today works in 10 years
- More transparent - You understand exactly what's happening
All examples in this book are:
- Production-ready - Not just toy demos
- Modern - Using ES6+ features and modern APIs
- Practical - Solving real problems you face daily
- Copy-paste friendly - Use them in your projects
Jump right in with any chapter that interests you:
- Want to see a complete app? Start with Chapter 8
- Curious about performance? Check out Chapter 9
- Need routing? Chapter 6 has you covered
- Just exploring? Begin with Chapter 1
By the end of this book, you'll be able to:
- Build complete web applications without frameworks
- Make informed decisions about when frameworks make sense
- Understand the trade-offs between frameworks and vanilla JS
- Write faster, lighter, more maintainable code
- Appreciate the power of the web platform
This book advocates for vanilla JavaScript, but it's not dogmatic. The goal isn't to convert you into a framework-hating zealot. The goal is to give you options.
Sometimes React is the right choice. Sometimes Vue makes sense. Sometimes Svelte is perfect.
And sometimes—more often than you might think—vanilla JavaScript is all you need.
Read the chapters in order for a complete journey, or jump to specific topics as needed. Each chapter builds on previous concepts but can stand alone.
Start with Chapter 1: The Framework Detox and begin your journey to understanding the true virtues of vanilla JavaScript.
This book is:
- Practical, not academic
- Opinionated, but fair
- Modern, not nostalgic
- Realistic, not idealistic
It uses humor to make learning enjoyable while seriously teaching you how to build real applications.
Found a typo? Have a suggestion? Want to add an example? Contributions are welcome!
This book is meant to be shared and learned from. Use the code examples freely in your projects.
Ready to rediscover the web platform?
Start with Chapter 1 →
"The best framework is the one you don't need."