Dev.Util.Web
1.3.0
See the version list below for details.
dotnet add package Dev.Util.Web --version 1.3.0
NuGet\Install-Package Dev.Util.Web -Version 1.3.0
<PackageReference Include="Dev.Util.Web" Version="1.3.0" />
<PackageVersion Include="Dev.Util.Web" Version="1.3.0" />
<PackageReference Include="Dev.Util.Web" />
paket add Dev.Util.Web --version 1.3.0
#r "nuget: Dev.Util.Web, 1.3.0"
#:package Dev.Util.Web@1.3.0
#addin nuget:?package=Dev.Util.Web&version=1.3.0
#tool nuget:?package=Dev.Util.Web&version=1.3.0
Dev.Util.Web
Web and URL utilities for the Dev.Util ecosystem. Effortlessly handle query strings, URL validation, and path orchestration for web applications.
📦 Installation
dotnet add package Dev.Util.Web
✨ Features
- 🔗 Query String Orchestration: Convert objects or dictionaries to standard URL query strings.
- 🏗️ Structured URL Combining: Combine base URLs and paths without worrying about trailing slashes.
- 🛡️ Validation: Built-in logic for Email and URL format verification.
- 🔠 Encoding/Decoding: Fluent extensions for URL-safe string transformations.
- 🛠️ Parameters: High-performance extraction of values from URL patterns.
🛠 Usage Examples
1. Robust URL Combining
Never worry about double slashes // or missing separators again.
using Dev.Util.Web;
string api = "https://api.myapp.com/";
string v = "/v1/";
string route = "users";
// Automatically cleans up slashes
string fullUrl = WebExtensions.Combine(api, v, route);
// Result: "https://api.myapp.com/v1/users"
2. Dynamic Query String Generation
Transform your filter objects directly into valid query parameters.
using Dev.Util.Web;
var filters = new {
Query = "Search Term",
Page = 5,
IncludeDetails = true
};
string qs = filters.ToQueryString();
// Result: "?Query=Search+Term&Page=5&IncludeDetails=true"
3. Integrated Web Validation
Validate inputs before processing requests.
using Dev.Util.Web;
string input = "not-an-email";
if (!input.IsValidEmail())
{
return BadRequest("Invalid Email Address");
}
if ("https://google.com".IsValidUrl()) {
// ...
}
4. URL-Safe Encoding
using Dev.Util.Web;
string data = "Hello World & Friends";
string safe = data.UrlEncode();
// Result: "Hello%20World%20%26%20Friends"
string back = safe.UrlDecode();
Dev.Util.Web is framework-agnostic. It works perfectly in Console apps, ASP.NET Core, or Blazor applications.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 is compatible. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- Dev.Util.Core (>= 1.3.0)
-
net8.0
- Dev.Util.Core (>= 1.3.0)
-
net9.0
- Dev.Util.Core (>= 1.3.0)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Dev.Util.Web:
| Package | Downloads |
|---|---|
|
Dev.Util
The complete Dev.Util ecosystem for .NET. One package to rule them all. Provides access to Core, Collections, IO, Security, Web, Reflection, Tasks, and Json modules. |
GitHub repositories
This package is not used by any popular GitHub repositories.