You Don't Need JavaScript

A practical guide to creating modern websites and interfaces using only CSS

    Cover of You Don't Need JavaScript

    PDF · English

    Price and availability

    PDF eBookUS store

    $28.99

    Sign in to buy

    You’ll review your order and final price before payment.

    Download from your library after delivery. Protected eBooks need a compatible reading app.

    For personal use under the eBook licence.

    Territorial availability

    Available in: Andorra, Austria, Australia, Belgium, Bulgaria, Canada, Switzerland, Cyprus, Czechia, Germany, Denmark, Estonia, Spain, Finland, France, United Kingdom, Guernsey, Greece, Croatia, Hungary, Ireland, Isle of Man, Iceland, Italy, Jersey, Japan, Liechtenstein, Lithuania, Luxembourg, Latvia, Monaco, Malta, Netherlands, Norway, Poland, Portugal, Romania, Sweden, Slovenia, Slovakia, San Marino, United States, Vatican City, South Africa

    Publisher rights cover these stores: US, UK, Canada, EU, Australia. Checkout availability is shown above.

    Format
    PDF
    DRM
    Not stated by the publisher
    Language
    English
    Publisher
    Packt Publishing
    Published
    6 July 2026
    ISBN
    9781807783402
    Subjects

    About this book

    A CSS-first guide to replace unnecessary JavaScript with modern HTML and CSS. Learn to build modals, dark mode, smooth scrolling, form validation, popovers, and more with modern HTML and CSS.Key FeaturesBuild common UI patterns with modern HTML and CSS instead of unnecessary JavaScriptLearn solid production techniques and latest platform features you can adopt with progressive enhancementExplore real interface problems about accessibility, performance, and maintainability with real-world examplesBook DescriptionFor years, JavaScript has been the default answer for almost every interactive detail on the web. Need a modal, a dropdown, dark mode, smooth scrolling, or form validation? Most frontend developers reach for JavaScript without thinking twice. But the platform has changed. This book shows how much modern HTML and CSS can already do on their own. Through practical examples, you will learn how to build real interface patterns with less code, fewer dependencies, and a stronger focus on accessibility, performance, and maintainability. You will explore features such as :has(), native dialogs, accordions, sliders, counters, dark mode, smooth scrolling, form validation, border animations, view transitions, motion paths, and mask effects. The book also introduces newer browser features like popovers, anchor positioning, scroll-driven animations, customizable selects, and CSS carousels. The goal is not to avoid JavaScript at all costs. It is to use it when it actually adds value, and not by default. By the end of the book, you will have a clearer sense of what the platform can handle today and how to build interfaces that are lighter, cleaner, and more resilient.What you will learnApply the Rule of Least Power in real UI decisionsChoose modern HTML and CSS over JS where it's sufficientBuild lightweight, accessible interfaces in practiceUse modern CSS features like :has(), view transitions, motion paths, masks, popovers, and anchor positioningCreate UI patterns like dark mode, dialogs, accordions, smooth scrolling, custom selects, and carouselsImplement progressive enhancement in real projectsImprove performance by reducing unnecessary JSWho this book is forThis book is for people who build interfaces and want to rely less on JavaScript when they do not have to. It is aimed at front-end developers, designers who code, and curious CSS people who already know the basics and want to see how far modern HTML and CSS can really go. If you have ever added JavaScript out of habit for something the browser can already handle, this book will give you a different way to think about that.]]>

    Bibliographic data © Gardners Books Ltd.