André Kovac

What the heck do "declarative" and "reactive" actually mean?

Are you telling the DOM how to change, or just what it should look like? Understand the fundamental difference between imperative and declarative programming.

What the heck do "declarative" and "reactive" actually mean?
#1about 2 minutes

Understanding imperative vs declarative with an analogy

An analogy of tidying a room illustrates the difference between giving step-by-step instructions (imperative) and describing the desired final state (declarative).

#2about 7 minutes

The challenge of manual DOM manipulation in JavaScript

A vanilla JavaScript counter example demonstrates the imperative process of manually querying and updating the DOM to synchronize application state with the UI.

#3about 3 minutes

How the browser renders HTML, CSS, and JavaScript

An overview of the browser's rendering pipeline shows how it converts HTML and CSS into a DOM and CSSOM to paint pixels on the screen.

#4about 4 minutes

Introducing the core concepts of reactive programming

Reactive programming is introduced using a spreadsheet analogy, where changing one value automatically updates all dependent values, aiming for a UI that is a function of its state.

#5about 5 minutes

Abstracting DOM updates with a custom state object

A simple state object with a `setValue` method is created to encapsulate imperative DOM manipulation, making the event handler more declarative.

#6about 4 minutes

The imperative pitfalls of conditional UI rendering

Attempting to conditionally add an element to the DOM imperatively reveals common bugs and makes the UI difficult to reason about from the code.

#7about 3 minutes

How React enables declarative UI with a virtual DOM

React's declarative approach is demonstrated, using a virtual DOM and the `useState` hook to describe the UI's appearance based on state.

#8about 2 minutes

Svelte's approach to truly reactive state updates

Svelte simplifies reactivity by making standard JavaScript assignments automatically trigger UI updates, removing the need for setter functions.

Related jobs
Jobs that call for the skills explored in this talk.

test

Milly
Vienna, Austria

Intermediate

test

Milly
Vienna, Austria

Intermediate

Featured Partners

Related Articles

View all articles
CH
Chris Heilmann
Dev Digest 136 - No JS(on) of mine
News and ArticlesDouglas Crockford is our featured video, so let's talk about evolving JavaScript and all things JSON. Judicious JSON explains all the weird things in it, you can learn why it can be incredibly slow, people wonder what even is a JSON ...
Dev Digest 136 - No JS(on) of mine
LM
Luis Minvielle
The Best 7 Frontend Frameworks for Developers in 2025
Which frontend frameworks should developers focus on in 2025? We’re listing them for you and showing advantages and drawbacks. You’ll notice we included some libraries as well, because you can’t miss those in 2025.What is the best front end framework...
The Best 7 Frontend Frameworks for Developers in 2025
AP
Anto Pranjić
That was WeAreDevelopers World Congress 2022
Thank you, danke, hvala, merci, gracias, Дякую – we don’t know yet exactly how many languages were spoken here at the City Cube Berlin over the last two days, but thank you 10 000 times to everybody who joined us here for WeAreDevelopers World Congre...
That was WeAreDevelopers World Congress 2022
DC
Daniel Cranney
The State of HTML 2024: What can we learn from it?
The results of the State of HTML 2024 survey are in! Though the name suggests it’s HTML-only, the survey focuses on the web platform in a more general sense, giving us some fascinating insights into not only the state of the web, but also some sense ...
The State of HTML 2024: What can we learn from it?

From learning to earning

Jobs that call for the skills explored in this talk.