Patterns for Reactivity with Modern Vanilla JavaScript
Reactivity is how systems react to changes in data and is core to web development. Learn JavaScript reactivity patterns to add to your toolbox, no matter what frameworks and libraries you use!
The revolutionary ideas that empowered the Web.
A simpler approach to building applications on the Web and beyond with htmx and Hyperview.
Enhancing web applications without using SPA frameworks.
Yesterday, we looked at where traditional DOM manipulation starts to break down when building complex JavaScript apps.
When you find yourself making lots of UI updates that require you to be aware of the current state of other UI elements, it might be time to consider using a different approach: state-based UI.
Let’s dig in!
What is state-based UI? With state-based UI, you hold data about the UI and how it should look in one or more JavaScript variables, called state.
#84 Die Evolution von JavaScript: Vom Ducktyping zum Monopol im Browser mit Peter Kröner - Engineering Kiosk
JavaScript: Eine multiparadigmatische Skriptsprache mit einem schwachen dynamischen Ducktyping-System. Um die Sprache JavaScript kommt man im Web nicht mehr vorbei. Die meisten kennen sie durch Frameworks wie React, Angular, Vue.js, Next und Co. Doch wie viel weißt du über die Hintergründe und die Weiterentwicklung dieser Sprache? In dieser Episode geht es nicht um das nächste hippe JavaScript-Framework, sondern wir sprechen mit Peter Kröner darüber, wie JavaScript erfunden wurde, was ECMAScript ist, wie TypeScript in den Mix spielt, warum die Sprache so beliebt ist, wie neue Features den Weg in die Sprache finden, was das TC39 ist, über das Monopol im Browser, verschiedene JavaScript-Engines und viel mehr. Bonus: Wenn Hamburg im Süden liegt. **** Diese Episode wird gesponsert vom Open-Source Förderprogramm Media Tech Lab: Bewirb dich jetzt und erhalte bis zu 50.000€ Fördersumme für dein Open-Source Projekt https://www.media-lab.de/de/media-tech-lab Das schnelle Feedback zur Episode: 👍 (top) 👎 (geht so)
As we build sites that are more heavily reliant on JavaScript, we sometimes pay for what we send down in ways that we can’t always easily see. In this talk, ...
Getting Started with Modern JavaScript — Template Literals - JavaScript inDepth
Introduced in 2015 with ECMAScript6, template literals let us dynamically construct strings of text and embedded expressions, even multi-line strings of text, in a more elegant way than concatenation.
Ein Intersection Observer beobachtet den Bereich 'below the fold' (unter dem sichtbaren Ausschnitt im Browserfenster), um Animationen zu starten oder als Basis für Lazy Loading.
Timing element visibility with the Intersection Observer API - Web APIs | MDN
In this article, we'll build a mock blog which has a number of ads interspersed among the contents of the page, then use the Intersection Observer API to track how much time each ad is visible to the user. When an ad exceeds one minute of visible time, it will be replaced with a new one.
The IntersectionObserver interface of the Intersection Observer API provides a way to asynchronously observe changes in the intersection of a target element with an ancestor element or with a top-level document's viewport. The ancestor element or viewport is referred to as the root.
Execute a function when a div is visible, using the intersection observer
When div appears on screen, i need to run a function
but since i am new to javascript i couldn't succeed.
how can i do it using intersection observer
<div id='demo'/>
my function
function my...
Videos paused outside viewport with IntersectionObserver
I created this function that stops the videos from playing when they are outside the viewport. It doesn't work. Can you help fix it?
const observer = new IntersectionObserver(entries => {
e...
Intersection observer for multiple videos on the same page
I have a portfolio page made in WordPress and on the page I have 5 videos that need to be played when in viewport and stopped when out of viewport.
I have used the following script that works only ...
A Few Functional Uses for Intersection Observer to Know When an Element is in View | CSS-Tricks
You might not know this, but JavaScript has stealthily accumulated quite a number of observers in recent times, and Intersection Observer is a part of that
Intersection Observer is an amazing tool in JavaScript that allows you to easily and efficiently do pretty much anything based on the visibility of elements....