Introduction
Welcome to our session on Network Analysis and Performance! Today, we'll dive deeper into understanding how web applications interact with servers, how to analyze network traffic, and how to optimize your application's performance.
Think of network performance as the highway system for your web application. Just as traffic congestion can delay travelers, inefficient network operations can create bottlenecks that frustrate users and diminish their experience. By mastering network analysis, you'll be equipped to build web applications that communicate efficiently across the internet.
By the end of this session, you'll understand how to identify network performance issues, implement effective optimizations, and validate improvements using browser developer tools.
The Client-Server Communication Model
To effectively analyze network performance, we must first understand how browsers and servers communicate.
The Request-Response Cycle
Every interaction with a web application follows this basic pattern:
- Request initiation: Browser forms an HTTP request with specific method, headers, and possibly body content
- DNS resolution: Browser converts domain name to IP address (if not cached)
- Connection establishment: TCP connection is opened, possibly with TLS handshake for HTTPS
- Request transmission: HTTP request is sent to the server
- Server processing: Server receives request, processes it, and generates response
- Response transmission: Server sends HTTP response back to browser
- Resource processing: Browser processes response (renders HTML, executes JavaScript, etc.)
Real-world analogy: This process is similar to ordering at a restaurant. You (the browser) place an order (request) with specific instructions. The server (kitchen) processes your order and returns your meal (response). Just as a complex meal requires multiple trips to the kitchen, a complex webpage requires multiple requests for various resources.
HTTP Protocol Fundamentals
HTTP (Hypertext Transfer Protocol) is the foundation of data communication on the web. Understanding its components is crucial for effective network analysis.
HTTP Methods
| Method | Purpose | Common Use Cases |
|---|---|---|
| GET | Request data from a specified resource | Page loads, API data retrieval, image loading |
| POST | Submit data to be processed to a specified resource | Form submissions, API data creation |
| PUT | Update a specified resource with new data | API updates to existing resources |
| DELETE | Delete a specified resource | API resource removal |
| PATCH | Apply partial modifications to a resource | API partial updates |
| HEAD | Request headers only (no response body) | Checking if resource exists or has been modified |
| OPTIONS | Get supported methods for a resource | CORS preflight requests |
Real-world example: A social media application might use GET to retrieve the news feed, POST to publish a new post, PUT to edit an existing post, and DELETE to remove a post—each method representing a different type of interaction with the server.
HTTP Status Codes
Status codes indicate the result of the HTTP request:
- 1xx (Informational): Request received, continuing process
- 2xx (Success): Request successfully received, understood, and accepted
- 200 OK: Standard success response
- 201 Created: Resource successfully created
- 204 No Content: Request succeeded but no content returned
- 3xx (Redirection): Further action needed to complete request
- 301 Moved Permanently: Resource has new permanent URI
- 302 Found: Resource temporarily located at another URI
- 304 Not Modified: Resource hasn't changed (used with conditional requests)
- 4xx (Client Error): Request contains bad syntax or cannot be fulfilled
- 400 Bad Request: Server couldn't understand the request
- 401 Unauthorized: Authentication required
- 403 Forbidden: Server understood but refuses to authorize
- 404 Not Found: Resource doesn't exist
- 429 Too Many Requests: Rate limiting applied
- 5xx (Server Error): Server failed to fulfill valid request
- 500 Internal Server Error: Generic server error
- 502 Bad Gateway: Server as gateway received invalid response
- 503 Service Unavailable: Server temporarily unavailable
- 504 Gateway Timeout: Server as gateway timed out
Real-world example: During a high-traffic sale, an e-commerce developer noticed a pattern of 504 errors in the payment processing API. By isolating these requests in the network panel, they identified that the payment gateway was timing out during peak loads, allowing them to implement retry logic and queue systems to improve resilience.
HTTP Headers
Headers provide additional information about requests and responses:
Common Request Headers:
- Accept: Content types the client can process
- Authorization: Authentication credentials
- Content-Type: Media type of request body
- User-Agent: Client application information
- Referer: Address of previous web page
- Cookie: Stored HTTP cookies
Common Response Headers:
- Content-Type: Media type of response
- Content-Length: Size of response body in bytes
- Cache-Control: Directives for caching mechanisms
- Set-Cookie: Send cookies from server to client
- Access-Control-Allow-Origin: CORS permissions
- ETag: Version identifier for a specific resource
Real-world example: A development team improved their app's performance by 30% by analyzing response headers and implementing proper Cache-Control and ETag mechanisms, allowing browsers to reuse previously fetched resources instead of downloading them again.
Network Panel Deep Dive
Let's explore the Chrome DevTools Network panel in more detail, learning how to extract meaningful insights from network activity.
Network Panel Layout
The Network panel consists of several key components:
- Controls: Record, clear, filter, preserve log, and disable cache
- Overview: Timeline visualization of network activity
- Request List: Table of all network requests
- Summary: Aggregate statistics (requests, data transferred, load times)
- Detail Pane: In-depth information about selected requests
Advanced Filtering Techniques
Effectively filtering network requests helps identify specific issues:
- Type filters: Use built-in filters (XHR, JS, CSS, Img, Media, Font, Doc, WS, Manifest)
-
Property filters: Use syntax like
status-code:404ormethod:POST -
Negative filters: Use minus sign to exclude (e.g.,
-status-code:200) - Multiple filters: Combine filters using space (logical AND)
Example combined filter: method:POST larger-than:10k (finds POST requests larger than 10KB)
Real-world example: A team troubleshooting sporadic API failures used the filter status-code:500 method:POST to isolate only failing POST requests, quickly identifying a pattern of server errors occurring when specific payload structures were submitted.
Waterfall Analysis
The waterfall chart shows the timing breakdown for each request:
Key phases to analyze in the waterfall:
- Queuing: Request waiting due to browser limitations or prioritization
- DNS Lookup: Time to resolve domain name to IP address
- Initial Connection: Time to establish TCP connection
- TLS Setup: Time for TLS/SSL handshake (HTTPS only)
- Request Sent: Time to send HTTP request to server
- Waiting (TTFB): Time to first byte – server processing time
- Content Download: Time to receive complete response
Real-world example: An e-commerce development team analyzed their waterfall chart and discovered unexpectedly long TTFB values for product data. This led them to investigate server-side caching issues, resulting in a 70% reduction in API response times after implementing Redis cache.
Connection View
The Connection column in the Network panel shows how resources are delivered:
- h2: HTTP/2 protocol
- h3: HTTP/3 protocol (QUIC)
- websocket: WebSocket connection
- ServiceWorker: Resource served by service worker
- (prefetch cache): Resource from prefetch cache
- (disk cache): Resource from disk cache
- (memory cache): Resource from memory cache
Real-world example: A team optimizing a news website noticed that HTTP/1.1 connections were limiting concurrent downloads. After upgrading their server to support HTTP/2, the Connection column showed "h2" for resources, and page load times decreased by 40% due to multiplexed connections.
Performance Metrics and Core Web Vitals
Understanding modern performance metrics is essential for creating fast, user-friendly web experiences.
Traditional Performance Metrics
- Page Load Time: Time from navigation start until the load event
- Time to First Byte (TTFB): Time from request to first byte received
- DOMContentLoaded: HTML parsed, DOM constructed (without waiting for resources)
- First Paint: First pixel rendered to the screen
Limitation: These metrics don't necessarily reflect the user's perception of performance. A page may technically "load" quickly but feel slow if important content isn't visible or interactive.
Core Web Vitals
Google's Core Web Vitals focus on user-centric performance metrics:
LCP] A --> C[First Input Delay
FID] A --> D[Cumulative Layout Shift
CLS] B --> B1[Loading Performance] C --> C1[Interactivity] D --> D1[Visual Stability] B1 --> B2[Good: ≤ 2.5s] B1 --> B3[Needs Improvement: 2.5s - 4s] B1 --> B4[Poor: > 4s] C1 --> C2[Good: ≤ 100ms] C1 --> C3[Needs Improvement: 100ms - 300ms] C1 --> C4[Poor: > 300ms] D1 --> D2[Good: ≤ 0.1] D1 --> D3[Needs Improvement: 0.1 - 0.25] D1 --> D4[Poor: > 0.25]
Largest Contentful Paint (LCP)
LCP measures when the largest content element in the viewport becomes visible.
- What it captures: Loading performance as perceived by users
- Good target: ≤ 2.5 seconds
- Typical LCP elements: Large images, video posters, background images, text blocks
Real-world example: An online magazine improved their LCP from 4.2s to 1.8s by implementing lazy loading for below-the-fold images, optimizing critical CSS delivery, and using responsive image techniques for hero images, resulting in a 23% increase in reader engagement.
First Input Delay (FID)
FID measures the time from when a user first interacts with your page to when the browser can respond to that interaction.
- What it captures: Responsiveness and interactivity
- Good target: ≤ 100 milliseconds
- Common causes of poor FID: Heavy JavaScript execution, third-party code, long tasks
Real-world example: A social media application reduced FID from 250ms to 70ms by breaking long JavaScript tasks into smaller chunks, deferring non-critical scripts, and implementing Web Workers for data processing. This resulted in a 15% reduction in bounce rate from the feed page.
Cumulative Layout Shift (CLS)
CLS measures visual stability by quantifying unexpected layout shifts during page load.
- What it captures: Visual stability and usability
- Good target: ≤ 0.1
- Common causes of poor CLS: Images without dimensions, ads, embeds, or dynamically injected content
Real-world example: An e-commerce site reduced their CLS from 0.42 to 0.08 by setting explicit width and height attributes on all product images, reserving space for ads before they load, and precomputing layout requirements for dynamic content. This improvement reduced misclicks on the "Add to Cart" button by 26%.
Measuring Core Web Vitals
Several tools can help you measure and monitor Core Web Vitals:
- Chrome DevTools: Performance panel and Web Vitals overlay
- Lighthouse: Automated auditing tool in DevTools
- PageSpeed Insights: Online tool with lab and field data
- Chrome User Experience Report (CrUX): Real-user metrics database
- Web Vitals JavaScript library: For custom measurement in your apps
Real-world example: A team responsible for a large content site implemented automated Lighthouse testing in their CI/CD pipeline, ensuring that new code changes couldn't be deployed if they negatively impacted Core Web Vitals beyond established thresholds.
Common Network Performance Issues and Solutions
Let's examine frequent network performance bottlenecks and practical solutions for each.
Excessive HTTP Requests
Problem: Too many individual resource requests increase load time due to connection overhead.
Solutions:
-
Bundle assets: Combine multiple JavaScript or CSS files
// Instead of: <link rel="stylesheet" href="header.css"> <link rel="stylesheet" href="main.css"> <link rel="stylesheet" href="footer.css"> // Use: <link rel="stylesheet" href="bundle.css"> - CSS/JS sprites: Combine multiple images into one, using CSS to display portions
-
Data URIs: Embed small resources directly in HTML/CSS
/* Instead of: */ .icon { background-image: url('small-icon.png'); } /* Use: */ .icon { background-image: url('data:image/png;base64,iVBORw...'); } - Domain sharding: Distribute resources across multiple domains to overcome browser connection limits (useful for HTTP/1.1, but unnecessary with HTTP/2)
Real-world example: A developer reduced HTTP requests on an image-heavy portfolio site from 87 to 28 by using CSS sprites for interface elements, inlining critical CSS, and implementing a build process that automatically bundled JS modules. This reduced initial load time by 62% on 3G connections.
Unoptimized Images
Problem: Oversized or inefficiently formatted images are often the largest contributor to page weight.
Solutions:
-
Choose appropriate formats:
- JPEG: Photos and complex images with many colors
- PNG: Images with transparency or few colors
- SVG: Icons, logos, and illustrations
- WebP: Modern format with better compression than JPEG/PNG
- AVIF: Next-generation format with excellent compression
-
Responsive images: Serve different sizes based on viewport
<img src="small.jpg" srcset="medium.jpg 1000w, large.jpg 2000w" sizes="(max-width: 600px) 100vw, 50vw" alt="Responsive image"> -
Lazy loading: Load images only as they enter the viewport
<img src="example.jpg" loading="lazy" alt="Lazy loaded image"> - Image compression: Optimize images using tools like ImageOptim, TinyPNG, or build-time optimization
Real-world example: An online store reduced their product listing page size by 78% by implementing WebP images with JPEG fallbacks, generating appropriately sized thumbnails, and lazy loading images below the fold. This reduced bounce rates on mobile devices by 23%.
Render-Blocking Resources
Problem: CSS and JavaScript that block rendering of the page until they're downloaded and processed.
Solutions:
-
Critical CSS: Inline essential CSS for above-the-fold content
<head> <style> /* Critical CSS for visible content */ header { ... } .hero { ... } </style> <link rel="preload" href="styles.css" as="style" onload="this.onload=null;this.rel='stylesheet'"> <noscript><link rel="stylesheet" href="styles.css"></noscript> </head> -
Defer non-critical JavaScript: Use async or defer attributes
<script src="critical.js"></script> <script src="analytics.js" async></script> <script src="feature.js" defer></script> - Load order optimization: Ensure critical resources are discovered and requested early
Real-world example: A news website implemented critical CSS inlining and deferred all non-essential JavaScript, improving LCP by 1.8 seconds. This resulted in a 34% increase in pages per session as users could access content more quickly and reliably.
Inefficient Caching
Problem: Failing to leverage browser caching forces repeat downloads of static resources.
Solutions:
-
Cache-Control headers: Define how resources should be cached
// For resources that rarely change Cache-Control: public, max-age=31536000, immutable // For resources that may change occasionally Cache-Control: public, max-age=86400 // For dynamic content with validation Cache-Control: no-cache - ETag and Last-Modified headers: Enable conditional requests
-
Cache busting: Append version or hash to filenames for updated resources
// Instead of: <script src="app.js"></script> // Use: <script src="app.v2.js"></script> // or <script src="app.js?v=8e4c2f"></script> - Service Workers: Implement custom caching strategies for offline support
Real-world example: A travel booking site implemented a comprehensive caching strategy with fingerprinted asset filenames and appropriate Cache-Control headers. Repeat visitors experienced page loads that were 83% faster due to most resources being served from the browser cache.
Slow Third-Party Resources
Problem: External scripts, widgets, and embeds can significantly impact performance.
Solutions:
- Audit third-party impact: Use the Network panel to identify slow resources
-
Asynchronous loading: Prevent third-party code from blocking rendering
// Instead of: <script src="https://example.com/widget.js"></script> // Use: <script src="https://example.com/widget.js" async defer></script> - Self-host when possible: Host third-party resources on your own servers
-
Implement resource hints: Use dns-prefetch, preconnect for external domains
<link rel="preconnect" href="https://example.com"> <link rel="dns-prefetch" href="https://example.com"> - Lazy load third-party widgets: Load only when needed or visible
Real-world example: A marketing team analyzed their homepage performance and discovered that social media sharing widgets were adding 2.3 seconds to page load. By replacing them with lightweight, custom implementations that loaded on interaction, they improved LCP by 1.7 seconds and increased conversion rates by 8%.
Resource Hints and Preloading Strategies
Resource hints allow you to inform the browser about resources it will need, optimizing the loading process.
Types of Resource Hints
-
dns-prefetch: Resolves domain name to IP address in advance
<link rel="dns-prefetch" href="https://api.example.com">Best for: Third-party domains that will be used later
-
preconnect: Establishes early connections, including DNS, TCP, and TLS
<link rel="preconnect" href="https://cdn.example.com">Best for: Resources you'll need soon but don't know exact path
-
prefetch: Downloads resources that might be needed for future navigation
<link rel="prefetch" href="next-page.html">Best for: Resources for the next user action or page
-
preload: High-priority fetch for current page resources
<link rel="preload" href="critical-font.woff2" as="font" type="font/woff2" crossorigin>Best for: Critical resources that are discovered late in the page
-
prerender: Renders a page in the background for instant navigation
<link rel="prerender" href="likely-next-page.html">Best for: Pages with very high probability of being visited next
Optimizing Resource Loading with Resource Hints
Strategic implementation of resource hints requires understanding your application's resource requirements:
-
Critical fonts: Use preload to avoid FOIT (Flash of Invisible Text)
<link rel="preload" href="fonts/main.woff2" as="font" type="font/woff2" crossorigin> -
Hero images: Preload key visual elements
<link rel="preload" href="hero.jpg" as="image" imagesrcset="hero-1x.jpg 1x, hero-2x.jpg 2x"> -
Critical JavaScript paths: Preload modules needed for interactivity
<link rel="preload" href="critical-component.js" as="script"> -
Next-page resources: Prefetch based on likely user navigation patterns
<link rel="prefetch" href="product-details.js">
Real-world example: An airline booking application used analytics data to identify common user journeys and implemented prefetch for the most likely next pages. They also preloaded critical custom fonts and JavaScript components needed for the booking widget. These optimizations reduced perceived page transition times by 43% and increased booking completion rates by 12%.
Potential Pitfalls
While resource hints are powerful, they must be used judiciously:
- Bandwidth consumption: Prefetching can waste bandwidth on unused resources
- Prioritization conflicts: Too many preloads can dilute the benefit for truly critical resources
- Mobile considerations: Be especially careful on mobile networks where data may be limited
Best practice: Implement resource hints incrementally, measuring the impact of each addition on your performance metrics to ensure they provide tangible benefits.
Advanced Network Debugging Techniques
For complex performance issues, you may need to go beyond basic network analysis.
Request Blocking and Modification
Chrome DevTools allows you to block or modify network requests to test various scenarios:
- Open the Network panel
- Right-click any request
- Select "Block request URL" or "Block request domain"
Use case: Testing application resilience when third-party services are unavailable or identifying which external script is causing a performance issue.
Comparing Performance Profiles
Create multiple recordings under different conditions to identify patterns:
- Record baseline performance
- Make a single change (e.g., block a specific script)
- Record performance again
- Compare metrics to isolate impact
Use case: Quantifying the performance impact of specific optimizations or identifying which of several factors is causing a performance regression.
Network Throttling
Simulate various network conditions to test performance across different environments:
- Preset conditions: Fast 3G, Slow 3G, Offline
- Custom profiles: Define specific download/upload speeds and latency
Real-world example: A travel booking app used network throttling to test their progressive loading strategy for hotel search results. By simulating 3G connections, they identified that large hotel images were blocking rendering of search filters, leading them to implement a more effective lazy loading strategy that prioritized interactive elements.
Request Initiator Analysis
Identify what triggered each network request:
- In the Network panel, right-click column headers
- Select "Initiator" to show the column
- Click on initiator links to navigate to the source code that triggered the request
Use case: Tracking down unexpected API calls or identifying script dependencies that trigger cascading requests.
HAR File Analysis
HTTP Archive (HAR) files capture network session data for detailed analysis or sharing:
- Right-click in the Network panel and select "Save all as HAR with content"
- Analyze the file with tools like HAR Analyzer or share with team members
Real-world example: A QA team created a repository of HAR files capturing various user flows under different conditions. This allowed developers to reproduce and fix performance issues even when they couldn't directly observe the problematic environment.
Practical Exercise: Network Performance Optimization
Let's apply what we've learned to a practical exercise.
Scenario: E-commerce Product Listing Page
You're working on optimizing a product listing page that customers have reported as "sluggish." The page displays 24 products with images, descriptions, prices, and "Add to Cart" functionality.
Task 1: Baseline Measurement
- Load the page with network throttling set to "Fast 3G"
- Record key metrics: Total page load time, LCP, number of requests, total page size
- Identify the five largest resources by size
- Note which resources have the longest TTFB
Task 2: Resource Analysis
- Examine image resources to identify optimization opportunities
- Check for render-blocking resources in the critical path
- Identify potentially unnecessary third-party resources
- Analyze cache headers for static resources
Task 3: Optimization Plan
- Prioritize optimization opportunities based on potential impact
- Create a specific action plan with at least five optimizations
- Estimate the expected improvement for each optimization
Task 4: Implementation Simulation
- Use the DevTools Network request blocking to simulate removing unnecessary resources
- Apply resource hints (by editing HTML in the Elements panel) for critical resources
- Test the impact of each simulated optimization
Expected learning outcomes: Through this exercise, you'll practice identifying real-world performance bottlenecks, prioritizing optimizations based on impact, and validating improvements with browser tools—all essential skills for professional web development.
Case Study: Real-World Optimization
Let's look at a real-world case of network performance optimization:
Company: Global News Publication
Initial situation: A major news website was experiencing high bounce rates (>60%) on mobile devices. Analysis showed slow loading times were a key factor, with average LCP of 5.7 seconds on 4G connections.
Performance Audit Findings
- 95 HTTP requests on homepage load
- Unoptimized hero images (2-3MB each)
- 12 different analytics and ad-tech scripts loading synchronously
- No resource prioritization strategy
- Custom fonts blocking text display
- Ineffective caching policy
Optimization Strategy
-
Critical rendering path optimization:
- Identified and inlined critical CSS
- Deferred non-essential JavaScript
- Preloaded custom fonts with font-display: swap
-
Image optimization pipeline:
- Implemented WebP with JPEG fallbacks
- Created automated image resizing workflow
- Applied lazy loading for below-fold content
-
Third-party management:
- Consolidated analytics providers
- Implemented self-hosted tag manager
- Delayed ad loading until after content rendered
-
Caching strategy:
- Implemented asset fingerprinting
- Set appropriate Cache-Control headers
- Added service worker for offline reading
Results
- HTTP requests reduced from 95 to 37
- LCP improved from 5.7s to 1.9s on 4G connections
- Mobile bounce rate decreased from 60% to 38%
- Average session duration increased by 45%
- Ad revenue per session increased by 27% despite fewer ads
Key Learnings
- Prioritizing visible content rendering had the largest impact on user perception
- Third-party scripts were more detrimental to performance than initially estimated
- Automated optimization workflows were essential for maintaining gains over time
- Performance improvements directly translated to business metrics
This case study demonstrates how systematic network performance optimization can transform user experience and business outcomes, even for content-heavy sites with significant third-party dependencies.
Development Workflow Integration
For sustainable performance, integrate network optimization into your development workflow:
Performance Budgets
Set explicit limits on metrics like:
- Total page size: e.g., Maximum 1MB total transfer size
- Performance metrics: e.g., LCP < 2.5s on 4G
- Request count: e.g., Maximum 70 requests per page load
Implementation: Use tools like Lighthouse CI or custom monitoring to enforce budgets during development and prevent regressions.
Automated Testing
Integrate performance testing into your CI/CD pipeline:
- Run Lighthouse audits automatically on pull requests
- Compare key metrics against baseline values
- Block deployments that significantly degrade performance
Example tool: lighthouse-ci can be integrated with GitHub Actions, Jenkins, or other CI systems.
Monitoring Production Performance
Collect real-user metrics (RUM) to understand actual performance:
-
Web Vitals measurement:
// Simple implementation using web-vitals library import {getLCP, getFID, getCLS} from 'web-vitals'; function sendToAnalytics({name, value}) { const body = JSON.stringify({name, value}); // Use `navigator.sendBeacon()` if available navigator.sendBeacon('/analytics', body) || fetch('/analytics', {body, method: 'POST', keepalive: true}); } getCLS(sendToAnalytics); getFID(sendToAnalytics); getLCP(sendToAnalytics); - Performance dashboards: Visualize trends and identify potential issues early
- Alerting: Set up notifications for performance regressions
Real-world example: An online retailer created a custom performance dashboard showing Core Web Vitals across different pages, devices, and geographic regions. This allowed them to quickly identify when a code change or third-party update negatively impacted specific user segments, enabling targeted fixes before most users were affected.
Take-Home Assignment
Apply your network analysis skills to a real project:
-
Select a website to analyze: Choose either:
- A personal project you're working on
- Your company's website (with permission)
- A public website you use frequently
-
Conduct a comprehensive network audit:
- Analyze at least three different pages (e.g., homepage, product page, checkout)
- Test under at least two different network conditions
- Capture key metrics for each scenario
- Identify the top five performance bottlenecks
-
Create an optimization plan:
- Prioritize issues by potential impact and implementation effort
- Document specific recommendations with code examples where appropriate
- Estimate expected improvements
-
If possible, implement and measure changes:
- Apply at least three optimizations
- Document before/after metrics
- Analyze whether improvements met expectations
Expected outcome: A detailed performance analysis report that demonstrates your ability to identify, prioritize, and address network performance issues in real-world contexts. This makes an excellent portfolio piece for job applications.
Additional Resources
To further develop your network analysis skills:
Conclusion
Today, we've explored the fundamental concepts and practical techniques of network analysis and performance optimization. By understanding how browsers and servers communicate, identifying common bottlenecks, and applying targeted optimizations, you can create significantly faster and more responsive web applications.
Remember that performance optimization is an ongoing process rather than a one-time task. As your application evolves, new performance challenges will emerge, requiring continuous monitoring and refinement. The tools and techniques we've covered provide a solid foundation for addressing these challenges throughout your development career.
In our next session, we'll explore Debugging in the Browser, where we'll dive deeper into JavaScript debugging, DOM manipulation tracking, and error handling techniques.