Questions: Web Technologies
Back to Topics List

Web Technologies Questions

Page 12 of 13 (Displaying Questions 1101 – 1200 of 1207 Total)

1101. What is `Client-Side Rendering (CSR)`?

Show Answer

The process where the browser downloads a minimal HTML page and a large JavaScript bundle, and the client's JavaScript is responsible for rendering the entire DOM structure and content.

Added: Nov 30, 2025

1102. What is `Transpilation`?

Show Answer

The process of converting source code written in one language or version (e.g., TypeScript, ES6+) into another language or version (e.g., JavaScript ES5) that offers a similar level of abstraction.

Added: Nov 30, 2025

1103. What is `Minification`?

Show Answer

The process of removing all unnecessary characters from source code (e.g., whitespace, comments) without changing its functionality, resulting in smaller file sizes for deployment.

Added: Nov 30, 2025

1104. What is `Polyfilling`?

Show Answer

The technique of providing modern functionality to older browsers by adding necessary code (polyfills) that implements the missing features, ensuring consistent behavior across environments.

Added: Nov 30, 2025

1105. What is `Type Coercion` in JavaScript?

Show Answer

The automatic or implicit conversion of values from one data type to another (e.g., `1 + '2'` resulting in '12'), which can often lead to unexpected behavior.

Added: Nov 30, 2025

1106. What is `Weak Typing` in JavaScript?

Show Answer

A characteristic where variables are not strictly tied to a single data type, allowing implicit conversions between different types during operations.

Added: Nov 30, 2025

1107. What is `Currying`?

Show Answer

A functional programming technique where a function that takes multiple arguments is transformed into a sequence of functions, each taking a single argument.

Added: Nov 30, 2025

1108. What is the primary benefit of the `QUIC` network protocol over TCP?

Show Answer

It provides **multiplexing without head-of-line blocking** at the transport layer, and fast connection establishment (0-RTT/1-RTT handshakes), significantly reducing latency, especially for HTTP/3.

Added: Nov 30, 2025

1109. How does HTTP/3 relate to the QUIC protocol?

Show Answer

HTTP/3 uses QUIC as its underlying transport layer instead of TCP, enabling it to leverage QUIC's benefits like stream-level flow control and faster handshakes.

Added: Nov 30, 2025

1110. What is `Encrypted Client Hello (ECH)`?

Show Answer

An emerging TLS extension that encrypts the Client Hello message, including the server name, preventing network observers from seeing which website a user is visiting.

Added: Nov 30, 2025

1111. What does the `Content-Encoding: br` header refer to?

Show Answer

It indicates that the resource has been compressed using **Brotli**, a modern, highly efficient lossless compression algorithm developed by Google, often providing better compression ratios than Gzip.

Added: Nov 30, 2025

1112. How is `Long-Term Caching` typically achieved in modern web development?

Show Answer

By using **content hashing** (e.g., `app.c0f4f72f.js`) in file names. This ensures that the file name changes whenever the content changes, allowing browsers to safely cache the resource indefinitely.

Added: Nov 30, 2025

1113. What is the purpose of the `Service Worker Navigation Preload` feature?

Show Answer

It allows a Service Worker to start a network fetch for a resource simultaneously with the Service Worker startup process, eliminating the delay caused by the worker initialization time.

Added: Nov 30, 2025

1114. What does `self.skipWaiting()` do in a Service Worker?

Show Answer

It forces an installed Service Worker to immediately become the active worker, bypassing the waiting phase, which is often used in development or for critical updates.

Added: Nov 30, 2025

1115. What happens in the Node.js Event Loop's `check` phase?

Show Answer

It is where callbacks registered using `setImmediate()` are executed. This phase runs immediately after the poll phase and before the close callbacks.

Added: Nov 30, 2025

1116. What is the Node.js `Buffer` class used for?

Show Answer

It is used to handle **binary data** directly. It represents a raw memory allocation outside the V8 heap, making it efficient for I/O operations like reading files or handling network data.

Added: Nov 30, 2025

1117. Explain `Zero-Copy Optimization` in networking/file operations.

Show Answer

A technique that eliminates the CPU overhead of copying data from kernel space to user space and back to kernel space during data transfer, such as serving a static file directly from disk to a network socket.

Added: Nov 30, 2025

1118. What is the CSS `color-mix()` function?

Show Answer

A function that takes two colors and a color space, and returns the result of mixing them together (e.g., `color-mix(in srgb, red 40%, blue 60%)`).

Added: Nov 30, 2025

1119. What is the purpose of the CSS `text-wrap: balance` property?

Show Answer

It instructs the browser to attempt to balance the length of the lines of text in a block, often resulting in more visually appealing headings and short paragraphs.

Added: Nov 30, 2025

1120. What problem does the CSS `@scope` at-rule solve?

Show Answer

It allows developers to scope CSS styles to a specific part of the DOM tree, preventing styles from leaking out (upwards) or affecting deeply nested elements (downwards), solving many BEM issues.

Added: Nov 30, 2025

1121. What is the `ResizeObserver` API?

Show Answer

An API that reports changes to the dimensions of an element's content or border box, allowing developers to react to size changes without relying on the window's `resize` event.

Added: Nov 30, 2025

1122. What is the purpose of the `IntersectionObserver` API?

Show Answer

It provides an efficient way to asynchronously observe changes in the intersection of a target element with an ancestor element or with the top-level document's viewport (used for lazy loading).

Added: Nov 30, 2025

1123. What kind of changes does a `MutationObserver` monitor?

Show Answer

It monitors changes to the DOM tree, including modifications to element attributes, character data in text nodes, and the addition or removal of nodes.

Added: Nov 30, 2025

1124. What does the `CSS Paint API` (part of Houdini) allow developers to do?

Show Answer

It allows developers to programmatically generate an image (like a background or border) using a JavaScript function, opening up possibilities for custom, dynamic CSS values.

Added: Nov 30, 2025

1125. What does the `CSS Layout API` (part of Houdini) allow developers to do?

Show Answer

It allows developers to implement entirely new layout modes (e.g., a custom masonry layout) in JavaScript, which can be run in a dedicated worker thread.

Added: Nov 30, 2025

1126. Contrast `Cooperative Multitasking` with `Preemptive Multitasking` in the context of the browser.

Show Answer

JavaScript uses cooperative multitasking, meaning the script runs until completion or explicitly yields. Preemptive multitasking (used by the browser kernel) allows the operating system to interrupt a task forcibly.

Added: Nov 30, 2025

1127. Why is `form.requestSubmit()` better than `form.submit()`?

Show Answer

`requestSubmit()` behaves like a user action, firing the `submit` event and respecting the form's validation checks before submission, whereas `submit()` bypasses these checks.

Added: Nov 30, 2025

1128. Why is the `document.execCommand()` method deprecated?

Show Answer

It is deprecated because its behavior is inconsistent across browsers, it is synchronous, and it is considered a security risk for certain operations; it is replaced by modern APIs like `navigator.clipboard`.

Added: Nov 30, 2025

1129. What is the primary use case for the `Broadcast Channel API`?

Show Answer

It allows scripts running in different browser tabs, windows, iframes, or Web Workers on the same origin to communicate with each other by broadcasting messages to a channel.

Added: Nov 30, 2025

1130. How are `Performance.mark()` and `Performance.measure()` used in RUM (Real User Monitoring)?

Show Answer

They are used to record custom timestamps (`mark`) and calculate the duration (`measure`) between those marks, enabling developers to monitor specific, application-defined performance timings from real users.

Added: Nov 30, 2025

1131. What does the `Long Animation Frame (LoAF)` metric measure?

Show Answer

It measures the time duration of a slow update to the user interface, including the script execution, style, layout, and composite phases, providing a better indicator of UI jank than FID.

Added: Nov 30, 2025

1132. What is `SharedArrayBuffer` and why is it complex?

Show Answer

It is a special type of `ArrayBuffer` that can be shared concurrently between Web Workers and the main thread, enabling true multi-threading. It is complex because it requires strict cross-origin isolation headers (COOP/COEP) for security.

Added: Nov 30, 2025

1133. What is the primary security vulnerability of the `window.postMessage()` API?

Show Answer

It can be vulnerable to cross-site scripting (XSS) or data leaks if the developer does not verify the origin of the message or the format of the received data.

Added: Nov 30, 2025

1134. What is `WebRTC` primarily used for?

Show Answer

It is a free, open-source project that enables web browsers and mobile applications to communicate directly via **peer-to-peer (P2P)** real-time communication, including video, audio, and data transfer.

Added: Nov 30, 2025

1135. What are the roles of `ICE, STUN, and TURN` in WebRTC?

Show Answer

These are protocols used for connectivity: **ICE** finds the best path. **STUN** finds the public IP address. **TURN** is a relay server used as a fallback when a direct P2P connection cannot be established (e.g., due to firewalls).

Added: Nov 30, 2025

1136. What is the use case for the `Media Source Extensions (MSE)` API?

Show Answer

It allows JavaScript to feed media data (audio and video chunks) directly to the browser's media elements (`<audio>`, `<video>`), enabling features like adaptive streaming (e.g., Netflix, YouTube).

Added: Nov 30, 2025

1137. What is the use case for the `Encrypted Media Extensions (EME)` API?

Show Answer

It is used in conjunction with MSE to enable playback of protected content (Digital Rights Management or DRM) by interacting with a Content Decryption Module (CDM).

Added: Nov 30, 2025

1138. What is the purpose of the `WebXR Device API`?

Show Answer

It provides access to the output capabilities of Virtual Reality (VR) and Augmented Reality (AR) devices, allowing web developers to create immersive 3D experiences in the browser.

Added: Nov 30, 2025

1139. How does a `Trusted Types Policy` mitigate XSS vulnerabilities?

Show Answer

It defines rules for creating secure, type-checked objects that must be used before inserting data into "dangerous" sink functions (like `innerHTML`), ensuring the inserted data is safe.

Added: Nov 30, 2025

1140. What is the importance of the `COOP/COEP` headers?

Show Answer

They create a highly restrictive environment (cross-origin isolation) necessary to securely enable powerful, performance-critical APIs like `SharedArrayBuffer` and `Performance.measureUserAgentSpecifics`.

Added: Nov 30, 2025

1141. What is the purpose of the `Cross-Origin Opener Policy (COOP)` header?

Show Answer

It restricts the current document's ability to interact with the window that opened it (the opener), helping to prevent cross-origin leakage.

Added: Nov 30, 2025

1142. What is the purpose of the `Cross-Origin Embedder Policy (COEP)` header?

Show Answer

It prevents a document from loading any cross-origin resources that do not explicitly grant permission via CORS or the `Cross-Origin-Resource-Policy` header.

Added: Nov 30, 2025

1143. What is the security purpose of the `__Host-` and `__Secure-` cookie prefixes?

Show Answer

These prefixes enforce strict requirements (`Secure` and `Path=/`) on cookies, guaranteeing they are only sent over HTTPS and are isolated to the exact domain or path, mitigating cookie injection attacks.

Added: Nov 30, 2025

1144. What does the `Cache-Control: immutable` directive suggest to the browser?

Show Answer

It tells the browser that the resource will **never** change after it has been created, allowing the browser to skip revalidation checks, even when using the back/forward buttons.

Added: Nov 30, 2025

1145. Explain the `Cache-Control: stale-while-revalidate` directive.

Show Answer

It allows the browser to serve a cached response immediately (even if it is stale) while simultaneously sending a request to the server in the background to check for and fetch a newer version.

Added: Nov 30, 2025

1146. What is a `Cache Miss`?

Show Answer

A situation where a client (browser or CDN) requests a resource, but the requested resource is either not found in the cache or has expired, forcing the client to retrieve the resource from the origin server.

Added: Nov 30, 2025

1147. What does `Time to First Byte (TTFB)` primarily measure?

Show Answer

It measures the time it takes for the server to process a request and send back the very first byte of the response. It primarily measures **server processing time** and **network latency**.

Added: Nov 30, 2025

1148. What is `Tail Latency` in distributed systems?

Show Answer

The latency experienced by the slowest requests (e.g., the 99th percentile, P99), which is crucial to measure in large-scale systems because it can significantly impact user experience and service stability.

Added: Nov 30, 2025

1149. What does it mean for an HTTP method to be `Idempotent`?

Show Answer

It means that making multiple identical requests has the same effect as making a single request (e.g., GET, HEAD, PUT, DELETE). It does not mean the server response is identical, only the server state change.

Added: Nov 30, 2025

1150. What is the `HSTS Preload List`?

Show Answer

A list of domains hardcoded into major web browsers (like Chrome and Firefox) that forces HTTPS connection from the very first visit, eliminating the need for an initial, unencrypted request.

Added: Nov 30, 2025

1151. Why is `Public Key Pinning (HPKP)` deprecated?

Show Answer

It was deprecated due to the severe risks of denial-of-service and potential bricking of websites if misconfigured (e.g., accidentally pinning a certificate chain that expires or cannot be replaced).

Added: Nov 30, 2025

1152. Which protocol is defined by `RFC 7540`?

Show Answer

HTTP/2.

Added: Nov 30, 2025

1153. Which protocol is defined by `RFC 9110`?

Show Answer

A revision that consolidates and updates the core semantics and syntax for HTTP/1.1 and HTTP/2.

Added: Nov 30, 2025

1154. How does `HTTP Strict Transport Security (HSTS)` protect against Man-in-the-Middle (MITM) attacks?

Show Answer

It forces the browser to use HTTPS for all future communication with that domain, preventing protocol downgrade attacks where an attacker tries to force a switch from HTTPS to insecure HTTP.

Added: Nov 30, 2025

1155. What is the purpose of the `Upgrade-Insecure-Requests` header?

Show Answer

It is an HTTP header sent by the client, instructing the server to modify all `http` URLs in the response to `https` before serving the document.

Added: Nov 30, 2025

1156. What is the purpose of the `X-Frame-Options` header?

Show Answer

It is a deprecated but still common security header that prevents a document from being embedded in an `<iframe>`, `<frame>`, or `<object>`, mitigating clickjacking attacks.

Added: Nov 30, 2025

1157. Contrast `SameSite=Strict` and `SameSite=Lax` cookies.

Show Answer

`Strict` prevents the cookie from being sent with any cross-site request (even top-level navigations). `Lax` allows the cookie to be sent with top-level navigations (e.g., clicking a link) but blocks it for cross-site requests like images or iframes.

Added: Nov 30, 2025

1158. What is the primary use case for the `Web Locks API`?

Show Answer

It allows scripts running in different tabs, windows, or workers of the same origin to coordinate work by acquiring and releasing a named lock, preventing simultaneous execution of critical sections of code.

Added: Nov 30, 2025

1159. What is the purpose of the JavaScript `URLSearchParams` object?

Show Answer

It provides a utility API for working with the query string parameters of a URL, allowing easy reading and modification without manual string manipulation.

Added: Nov 30, 2025

1160. What is the `URL.createObjectURL()` method used for, and what is its limitation?

Show Answer

It creates a temporary DOMString containing a URL representing a `File` or `Blob` object, used for displaying local data (like an image) without uploading. The URL is valid only within the current document/origin.

Added: Nov 30, 2025

1161. What is `import.meta`?

Show Answer

A JavaScript object available within ES Modules that exposes metadata about the current module, such as the module's URL (`import.meta.url`).

Added: Nov 30, 2025

1162. What is the use case for `Intl.RelativeTimeFormat`?

Show Answer

It is used to format relative times (e.g., "in 5 minutes," "yesterday") in a localized and language-appropriate manner.

Added: Nov 30, 2025

1163. What is the use case for `Intl.DateTimeFormat`?

Show Answer

It is used to format dates and times (e.g., "Monday, July 1, 2024") according to the conventions of a specific language and locale.

Added: Nov 30, 2025

1164. What are some limitations of the JavaScript `Proxy` object?

Show Answer

A proxy cannot be created for built-in objects that have internal slots (like `Map`, `Set`, `Date`, or `Promise`), and it cannot proxy private class fields (`#field`).

Added: Nov 30, 2025

1165. What is the purpose of the `Reflect` object?

Show Answer

It provides methods that mirror the trap methods of the `Proxy` object, offering a standard way to intercept and handle JavaScript operations.

Added: Nov 30, 2025

1166. What does the `Symbol.iterator` property enable?

Show Answer

It enables an object to be iterable, allowing it to be consumed by constructs like the `for...of` loop and the spread operator (`...`).

Added: Nov 30, 2025

1167. What does a JavaScript `Generator function (*)` return?

Show Answer

It returns a **Generator object**, which is a special type of Iterator that can pause and resume execution using the `yield` keyword.

Added: Nov 30, 2025

1168. What is the purpose of the `yield*` expression in generator functions?

Show Answer

It is used to delegate to another iterable (like another generator or an array), effectively flattening nested iteration.

Added: Nov 30, 2025

1169. Why might `Web Components Polyfills` still be needed?

Show Answer

While browser support for the core specs (Custom Elements, Shadow DOM, HTML Templates) is good, polyfills might be needed for very old browsers or for experimental or less widely adopted features.

Added: Nov 30, 2025

1170. How does `Slotted Content` (`<slot>`) work with Shadow DOM?

Show Answer

A `<slot>` element acts as a placeholder inside the Shadow DOM where content from the element's light DOM (original content) is rendered, allowing external content to participate in the component.

Added: Nov 30, 2025

1171. What is a `Shadow Host`?

Show Answer

The regular DOM element to which the Shadow DOM is attached (e.g., the `<my-component>` tag itself).

Added: Nov 30, 2025

1172. What is the inheritance behavior of `CSS Custom Properties` (Variables)?

Show Answer

They follow the normal CSS cascade and inheritance rules, meaning a variable defined on a parent element can be accessed and used by all its descendant elements.

Added: Nov 30, 2025

1173. What is the `CSS Typed Object Model (CSSOM)` and why is it faster?

Show Answer

It is a modern API that exposes CSS values as typed JavaScript objects rather than strings, eliminating the need for string manipulation and parsing, resulting in faster and more maintainable code.

Added: Nov 30, 2025

1174. What is the proposed purpose of `requestPostAnimationFrame()`?

Show Answer

It is an intended counterpart to `requestAnimationFrame`, scheduling a callback to run synchronously *after* the browser has rendered the frame, useful for cleanup or non-visual tasks.

Added: Nov 30, 2025

1175. What is the main advantage of `CSS Container Queries` over Media Queries?

Show Answer

Media queries only query the size of the *viewport*. Container queries allow styling to be based on the size of the nearest *ancestor element* (the container), enabling true component-based responsiveness.

Added: Nov 30, 2025

1176. What is the basic syntax of the `@container` rule?

Show Answer

`@container <name> (<condition>) { ... styles ... }` where `<name>` is defined on an ancestor element using the `container-name` property.

Added: Nov 30, 2025

1177. What are some key additions in `CSS Media Queries Level 4`?

Show Answer

New media features like `prefers-color-scheme`, `prefers-reduced-motion`, and the ability to combine conditions with `and`, `or`, and `not`.

Added: Nov 30, 2025

1178. What is the use case for the CSS keyword `revert-layer`?

Show Answer

It reverts a property value to the value it would have had if the current cascade layer was not present, useful for selectively overriding rules in a component-specific layer.

Added: Nov 30, 2025

1179. When should you use the WAI-ARIA `role="application"`?

Show Answer

It should only be used when an element contains highly complex, non-standard desktop-like interface components (e.g., custom windowing systems) where standard ARIA roles are insufficient, and it requires careful focus management.

Added: Nov 30, 2025

1180. What is the `aria-owns` attribute used for?

Show Answer

It is used to establish a relationship between two elements when the DOM hierarchy does not accurately reflect the element's logical structure, allowing screen readers to understand the correct parent-child relationship.

Added: Nov 30, 2025

1181. How is the `Accessibility Tree` constructed?

Show Answer

It is constructed by the browser based on the DOM tree and augmented by semantic information from HTML tags (e.g., `<button>`) and WAI-ARIA attributes, providing assistive technologies with a model of the UI.

Added: Nov 30, 2025

1182. What is the minimum `Contrast Ratio` requirement for normal text according to WCAG 2.1 AA?

Show Answer

A minimum contrast ratio of **4.5:1** between the text and background color.

Added: Nov 30, 2025

1183. What is a `Headless CMS`?

Show Answer

A content management system that provides a backend-only content repository (database) but does not have a presentation layer (frontend), delivering content via an API (usually REST or GraphQL).

Added: Nov 30, 2025

1184. What is the definition of `JAMstack` architecture?

Show Answer

An architecture based on **J**avaScript, **A**PIs, and **M**arkup. It focuses on pre-built sites (SSG) served from a CDN, with dynamic functionality delegated to microservices via APIs.

Added: Nov 30, 2025

1185. What is `Edge Computing` in the context of the web?

Show Answer

It is the practice of processing data physically closer to the source (the user), often via CDN edge servers or specialized cloud functions, to reduce latency for dynamic content and APIs.

Added: Nov 30, 2025

1186. What is `Serverless Computing`?

Show Answer

A cloud computing model where the cloud provider manages the server infrastructure, automatically scaling resources and only charging for the resources consumed by the executed code, relieving the developer of server management.

Added: Nov 30, 2025

1187. What is `FaaS (Function as a Service)` an example of?

Show Answer

It is a deployment model for serverless computing, where developers deploy only a single function or piece of business logic (e.g., AWS Lambda, Google Cloud Functions).

Added: Nov 30, 2025

1188. What is the difference between `Observability` and `Monitoring`?

Show Answer

Monitoring tells you **if** the system is working (based on predefined metrics/alerts). Observability allows you to explore **why** it is not working by actively querying and correlating data (logs, traces, metrics).

Added: Nov 30, 2025

1189. What is the purpose of `Distributed Tracing`?

Show Answer

It allows developers to visualize and analyze the end-to-end flow of a request as it propagates through multiple services in a distributed microservices architecture, helping to locate performance bottlenecks and failures.

Added: Nov 30, 2025

1190. What is the `Saga Pattern` in microservices?

Show Answer

A way to manage distributed transactions across multiple services in a microservices environment, ensuring eventual consistency by sequencing local transactions and compensating/reversing them on failure.

Added: Nov 30, 2025

1191. Explain the `Strangler Fig Pattern` in migration.

Show Answer

A technique used to gradually refactor a monolithic application by building new service components (the "strangler") around the outside of the old system (the "fig"), eventually replacing it entirely without a disruptive single rewrite.

Added: Nov 30, 2025

1192. What is `Back-Pressure` in stream processing?

Show Answer

A state where a downstream consumer is processing data more slowly than an upstream producer is generating it. The system must apply "pressure" back to the producer to slow it down, preventing resource exhaustion.

Added: Nov 30, 2025

1193. Why are `WebSocket Keepalives` often necessary?

Show Answer

They are periodic, small frames sent over an idle WebSocket connection to prevent intermediate network devices (like load balancers or firewalls) from closing the connection due to inactivity.

Added: Nov 30, 2025

1194. What is the `Hacker News Effect`?

Show Answer

A phenomenon where a website is suddenly overwhelmed by a massive surge in traffic from a popular news aggregator or social media platform, often leading to a temporary crash or significant performance degradation.

Added: Nov 30, 2025

1195. What is `Rate Limiting`?

Show Answer

A technique used to control the rate of traffic sent or received by an application programming interface (API), protecting the service from abuse and ensuring fair usage for all clients.

Added: Nov 30, 2025

1196. What is `Jank` (UI) and what is its primary cause?

Show Answer

Jank is noticeable stuttering or freezing in animations and scrolling. It is primarily caused by **long-running tasks blocking the main thread**, preventing the browser from rendering the next frame within the 16.6ms budget.

Added: Nov 30, 2025

1197. What are the main steps in the browser's `Rendering Pipeline`?

Show Answer

The core steps are: **Style** (calculating styles) -> **Layout** (calculating geometry) -> **Paint** (filling pixels) -> **Composite** (drawing layers to screen).

Added: Nov 30, 2025

1198. What is the role of `GPU Rasterization` in browser rendering?

Show Answer

It is the process of converting the rendering commands and vector graphics (from the Paint step) into the actual pixels (bitmaps) that are displayed on the screen, often accelerated by the GPU.

Added: Nov 30, 2025

1199. How can a `Web Performance Budget` be programmatically enforced?

Show Answer

By integrating budget checks into the continuous integration (CI) pipeline, using tools like Lighthouse or Webpack bundlesize, which fail the build if performance metrics or bundle sizes exceed predefined limits.

Added: Nov 30, 2025

1200. How does the V8 Engine Garbage Collector (`Orinoco`) work at a high level?

Show Answer

It uses a generational approach, dividing the heap into young and old generations. It uses an incremental, concurrent process to minimize main thread pauses (stop-the-world).

Added: Nov 30, 2025