Commit Graph

11 Commits

Author SHA1 Message Date
Karl Seguin
be75b5b237 Add URL struct
Combine uri + rawuri into single struct.

Try to improve ownership around URIs and URI-like things.
 - cookie & request can take *const std.Uri
   (TODO: make them aware of the new URL struct?)
 - Location (web api) should own its URL (web api URL)
 - Window should own its Location

Most of these changes result in (a) a cleaner Page and (b) not having to carry
around 2 nullable objects (URI and rawuri).
2025-04-09 18:19:07 +08:00
Karl Seguin
fc0ec860b0 Tweak generate.Tuple and generate.Union
Leverage comptime fields to give generated Tuple a default value, allowing
TupleT and Tuple to be merged.

Only call generate.Tuple on the final output. This eliminates redundant
deduplication, and results in a simpler API (nested types just need to expose
a natural Zig tuple).

generate.Union leverages the new Tuple and removes unused features.
2025-02-01 14:53:00 +08:00
Pierre Tachoire
9cdf1f5762 xhr: fix unit tests for 0.12.1 2024-06-18 16:13:34 +02:00
Pierre Tachoire
ef364f83c8 upgrade to zig 0.12.1 2024-06-18 16:13:27 +02:00
Pierre Tachoire
6b42b5abdd anchor: implement HTMLHyperlinkElementUtils interface
https://html.spec.whatwg.org/#htmlhyperlinkelementutils
2024-05-14 13:44:27 +02:00
Pierre Tachoire
e12d6e85f0 url: add origin getter 2024-05-14 13:44:26 +02:00
Pierre Tachoire
d93a065db9 url: improve url format 2024-05-14 13:44:26 +02:00
Pierre Tachoire
2a3a243d1c add AGPL license header in zig files 2024-05-13 20:51:36 +02:00
Pierre Tachoire
d0c741f3bb url: search query dynamic and encoded 2024-05-06 16:32:20 +02:00
Pierre Tachoire
f7040153cd url: implement query parsing 2024-05-06 12:45:14 +02:00
Pierre Tachoire
28a87c2a47 url: first draft 2024-05-03 16:18:11 +02:00