Files
browser/src/notification.zig
Karl Seguin 2d5ff8252c Reorganize v8 contexts and scope
- Pages within the same session have proper isolation
  - they have their own window
  - they have their own SessionState
  - they have their own v8.Context

- Move inspector to CDP browser context
  - Browser now knows nothing about the inspector

- Use notification to emit a context-created message
  - This is still a bit hacky, but again, it decouples browser from CDP
2025-04-29 10:22:08 +08:00

24 lines
539 B
Zig

const URL = @import("url.zig").URL;
const browser = @import("browser/browser.zig");
pub const Notification = union(enum) {
page_navigate: PageNavigate,
page_navigated: PageNavigated,
context_created: ContextCreated,
pub const PageNavigate = struct {
timestamp: u32,
url: *const URL,
reason: browser.NavigateReason,
};
pub const PageNavigated = struct {
timestamp: u32,
url: *const URL,
};
pub const ContextCreated = struct {
origin: []const u8,
};
};