preload.spec.ts — vite Source File
Architecture documentation for preload.spec.ts, a typescript file in the vite codebase. 2 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR ada3aeba_c50c_8cf8_e113_badab903cf52["preload.spec.ts"] a340ba46_b2b7_3048_3bb3_6907a74c8464["vitest"] ada3aeba_c50c_8cf8_e113_badab903cf52 --> a340ba46_b2b7_3048_3bb3_6907a74c8464 d3fd5575_295b_d6be_24dd_62d277645dc9["~utils"] ada3aeba_c50c_8cf8_e113_badab903cf52 --> d3fd5575_295b_d6be_24dd_62d277645dc9 style ada3aeba_c50c_8cf8_e113_badab903cf52 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import { describe, expect, test } from 'vitest'
import { browserLogs, isBuild, page } from '~utils'
test('should have no 404s', () => {
browserLogs.forEach((msg) => {
expect(msg).not.toMatch('404')
})
})
describe.runIf(isBuild)('build', () => {
test('dynamic import', async () => {
await page.waitForSelector('#done')
expect(await page.textContent('#done')).toBe('ran js')
})
test('dynamic import with comments', async () => {
await page.click('#hello .load')
await page.waitForSelector('#hello output')
const html = await page.content()
expect(html).toMatch(
/link rel="modulepreload".*?href=".*?\/assets\/hello-[-\w]{8}\.js"/,
)
expect(html).toMatch(
/link rel="stylesheet".*?href=".*?\/assets\/hello-[-\w]{8}\.css"/,
)
})
})
Dependencies
- vitest
- ~utils
Source
Frequently Asked Questions
What does preload.spec.ts do?
preload.spec.ts is a source file in the vite codebase, written in typescript.
What does preload.spec.ts depend on?
preload.spec.ts imports 2 module(s): vitest, ~utils.
Where is preload.spec.ts in the architecture?
preload.spec.ts is located at playground/preload/__tests__/preload.spec.ts (directory: playground/preload/__tests__).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free