Phase 8 — Resource Loading + Character Encoding + Real Page Loading#
Implement the about:blank special URL that produces an empty HTML document.
Requirements#
- Recognize
about:blankas a special URL scheme - When navigating to
about:blank, create a minimal empty HTML document without any network fetch - The document should be:
<!DOCTYPE html><html><head></head><body></body></html> - Set the document's character encoding to UTF-8
- Set the origin appropriately (opaque origin for about:blank)
- This should be the default document when the browser starts with no URL argument
Integration Points#
urlcrate: recognizeabout:schemebrowsercrate: use as default document on startup- ResourceLoader: handle
about:blankwithout network fetch
Acceptance Criteria#
-
about:blankproduces a valid empty DOM tree - No network requests are made
- Document has correct encoding (UTF-8)
- Browser opens to about:blank when no URL is provided
- No external dependencies, no
unsafe - Unit test verifying DOM structure for about:blank
Dependencies#
Depends on: Resource loader (for integration), HTML parser (already complete)