WHATWG URL parser in C. Provides a memory efficient URL representation with immutable views over the various URL components, inspired by WebKit and Ada.
#include <url.h>
#include <utf.h>
url_t url
url_init(&url);
url_parse(&url, "https://example.com/foo/bar?baz", -1, NULL);
utf8_string_view_t href = url_get_href(&url);
url_destroy(&url);See include/url.h for the public API.
Apache-2.0