SolidJS·SolidJS essentials

Signals

Solid uses signals for fine-grained reactivity without a virtual DOM.

Intermediate 10 min read Lesson 1 of 150 Challenge included
What you will be able to do
  • createSignal returns a getter and setter.
  • Call the getter to track.
  • Components run once.

In plain English

Solid uses signals for fine-grained reactivity without a virtual DOM.

  • createSignal returns a getter and setter.
  • Call the getter to track.
  • Components run once.
Counter.jsxJavaScript
import { createSignal } from 'solid-js'

export default function Counter() {
  const [count, setCount] = createSignal(0)
  return <button onClick={() => setCount(count() + 1)}>Clicked {count()}</button>
}
Your turn

Explain it back

Easy

Answer from memory: How do you read a Solid signal?

TEXT · starter
Your answer…
Check your understanding before moving on.
Knowledge checkQuestion 1

How do you read a Solid signal?

Select an answer to continue
Study tools

Make it yours.

Keep a private note for this lesson, then turn the key ideas into flashcards you can revisit.

Sign in to save notes and flashcards.Both are private to your account and stay with your progress.
Sign in
Finished reading?

Lock in what you just learned.

Mark this lesson complete to save your place and move one step closer to the certificate.

Next: Memos and effects
Lesson 1 of 150 · 0% of course