a template string function to create urls and only keeping search params with values - based on this tweet
let filter = undefined;
let user = null;
let q = "my search";
urlString`https://site.com/path?q=${q}&user=${user}&filter=${filter}`;
// => "https://site.com/path?q=my+search"
import { UrlBuilder } from "@mcansh/url";
new UrlBuilder()
.domain("site.com")
.path("/path")
.param("q", "my search")
.param<number>("userId", 5)
.param<string>("filter", "category")
.build();
// => "https://site.com/path?q=my+search&userId=5&filter=category"