How Do You Fetch Data from an API with the Fetch API?
Learn to call APIs with fetch and async await: read JSON, send POST data, check status codes, handle errors and timeouts, and render the result.
94 posts about CSS: questions with answers, tutorials and articles, newest first.
Learn to call APIs with fetch and async await: read JSON, send POST data, check status codes, handle errors and timeouts, and render the result.
Add transparency to a CSS color with an alpha value from 0 to 1. See rgb, hsl and hex syntax, and when to use alpha instead of the opacity property.
Promises and async await let JavaScript handle slow work without callback pyramids. Learn states, chaining, error handling and running tasks in parallel.
HSL describes a color with hue, saturation and lightness. See how hsl() works and how to build shades, tints and themes by changing a single value.
Learn how events travel through the page and how to use addEventListener, event delegation and listener options to build responsive, efficient interfaces.
CSS colors can be written as names, hex codes or rgb() values. See how each notation works, how they convert, and how to pick one for your styles.
The DOM is the browser's live tree of your page. Learn to select elements and change text, classes and structure with JavaScript without security mistakes.
display: none removes an element and its space from the layout, while visibility: hidden hides it but keeps the space. Learn how each affects layout, focus and transitions.
Understand how JavaScript functions are declared and called, and how scope, closures and let, const and var decide which variables your code can see.
The display property controls how an element flows on the page. Compare block, inline and inline-block, and fix why width does not work on a span.
A beginner guide to declaring variables with let and const, the JavaScript data types, and the arithmetic, comparison and logical operators.
min(), max() and clamp() choose a CSS value at layout time. See how they work, how to build fluid text, and how to keep it accessible.
JavaScript is the language that makes web pages interactive. Learn what it is, how it relates to HTML and CSS, and what it can do in the browser.
The calc() function lets CSS mix units like percentages and pixels. Learn its operator rules, the spacing requirement and practical layout examples.
Learn the web accessibility basics: semantic HTML, text alternatives, labelled forms, keyboard focus, contrast, ARIA and how to test with assistive tools.
Percentages in CSS depend on the containing block. Learn why width works, why height needs a defined parent, and how padding percentages really work.
Make a site adapt to any screen using the viewport tag, fluid CSS and mobile first media queries, plus preference and container queries.
CSS viewport units size elements against the browser window. See how vw, vh, svh, lvh and dvh differ and which one fixes full-height mobile layouts.
Learn CSS Grid from tracks and the fr unit to responsive galleries, named grid areas, alignment and subgrid, and when to choose Grid over Flexbox.
Learn how px, em and rem are calculated in CSS, why nested em values compound, and which unit to choose for text, spacing and borders.