getErrorOverlayContent() — astro Function Reference
Architecture documentation for the getErrorOverlayContent() function in test-utils.js from the astro codebase.
Entity Profile
Dependency Diagram
graph TD e1e769bb_3791_17ce_1de0_e821705ee691["getErrorOverlayContent()"] 2ca394f6_a63d_3921_1f12_c5a979ea0039["test-utils.js"] e1e769bb_3791_17ce_1de0_e821705ee691 -->|defined in| 2ca394f6_a63d_3921_1f12_c5a979ea0039 style e1e769bb_3791_17ce_1de0_e821705ee691 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/astro/e2e/test-utils.js lines 67–86
export async function getErrorOverlayContent(page) {
const overlay = await page.waitForSelector('vite-error-overlay', {
strict: true,
timeout: 10 * 1000,
});
expect(overlay).toBeTruthy();
const message = await overlay.$$eval('#message-content', (m) => m[0].textContent);
const hint = await overlay.$$eval('#hint-content', (m) => m[0].textContent);
const [absoluteFileLocation, fileLocation] = await overlay.$$eval('#code header h2', (m) => [
m[0].title,
m[0].textContent,
]);
const codeFrame = await overlay.$('#code pre code');
const copyButton = await overlay.$('#copy-btn');
return { message, hint, absoluteFileLocation, fileLocation, codeFrame, copyButton };
}
Domain
Subdomains
Defined In
Source
Frequently Asked Questions
What does getErrorOverlayContent() do?
getErrorOverlayContent() is a function in the astro codebase, defined in packages/astro/e2e/test-utils.js.
Where is getErrorOverlayContent() defined?
getErrorOverlayContent() is defined in packages/astro/e2e/test-utils.js at line 67.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free