SolidJS: The Complete Guide
$34.00
Minimum price
$44.00
Suggested price

SolidJS: The Complete Guide

A comprehensive guide to reactive web development with SolidJS and TypeScript

About the Book

Solid may seem simple on the surface, but its internal workings involve complex interactions that can sometimes be tricky to explain. I rewrote the book twice to find the right balance—enough depth to capture the complexities without overwhelming readers.

This book is the fruit of two years of arduous work. It is a comprehensive book that aims to teach you the ins and outs of Solid, covering its core principles, the inner workings, and the API. By the end of this book, you will have a thorough understanding of SolidJS to write efficient applications.

Personally, I’m not comfortable using tools without understanding their inner workings and intricacies. This book goes beyond just showing you how to use SolidJS; it explains the reasoning and underlying principles behind the library, helping you understand why certain approaches or features work the way they do. With this deeper comprehension, you’ll be well-equipped to build your own projects confidently.

Please scroll down to see the table of contents and explore the topics covered in detail.

  • Share this book

  • Categories

    • JavaScript
    • TypeScript
    • Computers and Programming
    • SolidJS
    • SolidStart
  • Feedback

    Email the Author(s)

About the Author

Table of Contents

  • Chapter 01: Introduction
    1. The Solid Version Used
    2. Contact and Feedback
    3. Requirements
    4. Trying Solid via Online Playground
    5. Creating a Project From a Template
    6. Note For React Developers
  • Chapter 02: Setting Up a Development Environment
  • Chapter 03: On SolidJS
    1. The Problem Solid Solves
    2. How Solid Works?
      1. Reactive Data
      2. Composable UI
    3. The Advantages of Solid Over Its Alternatives
  • Chapter 04: How Solid’s Reactive System Works
    1. Observer Pattern
    2. The Essence of Reactive Core
    3. The Uses of Computations
  • Chapter 05: Tracking State With Signals
    1. Overwriting the comparison logic
    2. Updating Signals
    3. Transforming Signals
    4. Destructuring Signals
    5. Batching Updates
  • Chapter 06: Running Side-Effects with Effects
    1. Effects Can Be Nested
    2. Explicit Tracking
    3. Opting Out of Tracking
    4. Handling External Dependencies
  • Chapter 07: Caching Values with Memos
  • Chapter 08: Rules of JSX
    1. Elements Should Be Closed
    2. JSX Elements Can Be Nested
    3. Expressions Can Be Used Inside JSX Elements
    4. Elements Can Have Attributes
    5. Missing Attribute Values Default to true
    6. Comments
    7. Whitespaces Are Trimmed
  • Chapter 09: Composing User Interfaces
    1. Components Should Return A Single Root Element
    2. Components Accept Data Through Their props
    3. Adding Static Types To Components
    4. Components Can Have Children
    5. How Components Are Rendered
    6. Solid runs fine-grained updates
    7. Conditional Rendering
    8. Reactive props
    9. Props should be treated as read-only
    10. Destructuring Props Changes The Rendering Order
    11. Best Practices
  • Chapter 10: Working With Props
    1. Passing Data From Parent To Child
      1. Providing Controlled Access To Parent’s Data
    2. Passing Data From Child To Parent
    3. Sharing State Between Children
    4. Destructuring And Spreading Props
    5. Forwarding Multiple Props At Once
    6. Validating Props
  • Chapter 11: Sharing Data Through the Context API
    1. How Context API Works
    2. Best Practices
  • Chapter 12: Component Lifecycle
    1. onMount
    2. onCleanup
    3. Best Practices
  • Chapter 13: Accessing DOM Nodes With ref
    1. Forwarding Refs
    2. Using refs with external libraries
    3. Best Practices
  • Chapter 14: Working with Computations
    1. createComputed
    2. createRenderEffect
    3. createEffect
    4. createMemo
    5. createDeferred
    6. createReaction
  • Chapter 15: Handling Errors
    1. ErrorBoundary
    2. catchError
    3. Handling Asynchronous Errors
    4. Handling Event Handling Errors
  • Chapter 16: Working with Owners
    1. Running functions with a given owner
    2. Running effects in asynchronous context
  • Chapter 17: Styling Elements
    1. Using Inline Styles
    2. Applying Style Definitions
    3. Applying classes based on a condition
    4. Using The Imperative API
  • Chapter 18: Reactive Utilities
    1. batch
    2. untrack
    3. on
    4. createRoot
    5. mergeProps
    6. splitProps
    7. mapArray and indexArray
    8. observable
    9. from
    10. startTransition and useTransition
  • Chapter 19: A Better Conditional Rendering
    1. Switch and Match
  • Chapter 20: Working with Lists
    1. For
    2. mapArray
    3. Index
    4. indexArray
    5. Selecting Items with Selectors
  • Chapter 21: Rendering Components Outside Component Hierarchy
  • Chapter 22: Managing Complex States with Stores
    1. Accessing Data
    2. Updating Stores
    3. Limitations Related to Reactivity
    4. Store Utilities
      1. produce
      2. reconcile
      3. unwrap
      4. createMutable
  • Chapter 23: Abstracting Behavior With Custom Directives
    1. Extending JSX Type With Custom Directives
    2. Using Imported Directives
  • Chapter 24: Working with Asynchronous Data
    1. Decoupling Fetching From Rendering
  • Chapter 25: Using Resource API for Data Fetching
    1. Info Object
    2. Resource Actions
    3. Handling Errors
  • Chapter 26: Managing Loading States with Suspense
  • Chapter 27: Achieving Better Consistency with Transitions
  • Chapter 28: Coordinating Loading States
  • Chapter 29: Code Splitting and Lazy Loading
  • Chapter 30: Handling Events
    1. Using the on namespace
    2. Using the on: Namespace
    3. Using the oncapture: Namespace
    4. Using Custom Properties
    5. Using Refs
    6. Using Custom Directives
    7. Passing Data to the Event Handlers
  • Chapter 31: Dynamically Rendering Components
  • Chapter 32: Server Side Rendering
    1. Targeting The Server Context
    2. Targeting the Development Build
    3. Rendering A Solid App
  • Chapter 33: Solid Without JSX
    1. Solid with Tagged Template Literals
    2. Solid with Hyperscript
    3. Drawbacks
  • A1: Setting Development Environment Using Webpack
  • Index
  • About the Author

The Leanpub 60 Day 100% Happiness Guarantee

Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.

Now, this is technically risky for us, since you'll have the book or course files either way. But we're so confident in our products and services, and in our authors and readers, that we're happy to offer a full money back guarantee for everything we sell.

You can only find out how good something is by trying it, and because of our 100% money back guarantee there's literally no risk to do so!

So, there's no reason not to click the Add to Cart button, is there?

See full terms...

Earn $8 on a $10 Purchase, and $16 on a $20 Purchase

We pay 80% royalties on purchases of $7.99 or more, and 80% royalties minus a 50 cent flat fee on purchases between $0.99 and $7.98. You earn $8 on a $10 sale, and $16 on a $20 sale. So, if we sell 5000 non-refunded copies of your book for $20, you'll earn $80,000.

(Yes, some authors have already earned much more than that on Leanpub.)

In fact, authors have earnedover $14 millionwriting, publishing and selling on Leanpub.

Learn more about writing on Leanpub

Free Updates. DRM Free.

If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).

Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.

Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.

Learn more about Leanpub's ebook formats and where to read them

Write and Publish on Leanpub

You can use Leanpub to easily write, publish and sell in-progress and completed ebooks and online courses!

Leanpub is a powerful platform for serious authors, combining a simple, elegant writing and publishing workflow with a store focused on selling in-progress ebooks.

Leanpub is a magical typewriter for authors: just write in plain text, and to publish your ebook, just click a button. (Or, if you are producing your ebook your own way, you can even upload your own PDF and/or EPUB files and then publish with one click!) It really is that easy.

Learn more about writing on Leanpub