From 34e03cd981acc934c779c29400f6ade0cb9bf54a Mon Sep 17 00:00:00 2001 From: dwalker Date: Sun, 3 May 2026 00:13:27 -0400 Subject: initial commit --- dwalker.xyz/Pages/Error.cshtml | 26 ++++++++++++++++++++++++++ dwalker.xyz/Pages/Error.cshtml.cs | 20 ++++++++++++++++++++ dwalker.xyz/Pages/Index.cshtml | 11 +++++++++++ dwalker.xyz/Pages/Index.cshtml.cs | 10 ++++++++++ dwalker.xyz/Pages/Shared/_Layout.cshtml | 16 ++++++++++++++++ dwalker.xyz/Pages/_ViewImports.cshtml | 3 +++ dwalker.xyz/Pages/_ViewStart.cshtml | 3 +++ 7 files changed, 89 insertions(+) create mode 100644 dwalker.xyz/Pages/Error.cshtml create mode 100644 dwalker.xyz/Pages/Error.cshtml.cs create mode 100644 dwalker.xyz/Pages/Index.cshtml create mode 100644 dwalker.xyz/Pages/Index.cshtml.cs create mode 100644 dwalker.xyz/Pages/Shared/_Layout.cshtml create mode 100644 dwalker.xyz/Pages/_ViewImports.cshtml create mode 100644 dwalker.xyz/Pages/_ViewStart.cshtml (limited to 'dwalker.xyz/Pages') diff --git a/dwalker.xyz/Pages/Error.cshtml b/dwalker.xyz/Pages/Error.cshtml new file mode 100644 index 0000000..6f92b95 --- /dev/null +++ b/dwalker.xyz/Pages/Error.cshtml @@ -0,0 +1,26 @@ +@page +@model ErrorModel +@{ + ViewData["Title"] = "Error"; +} + +

Error.

+

An error occurred while processing your request.

+ +@if (Model.ShowRequestId) +{ +

+ Request ID: @Model.RequestId +

+} + +

Development Mode

+

+ Swapping to the Development environment displays detailed information about the error that occurred. +

+

+ The Development environment shouldn't be enabled for deployed applications. + It can result in displaying sensitive information from exceptions to end users. + For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT environment variable to Development + and restarting the app. +

diff --git a/dwalker.xyz/Pages/Error.cshtml.cs b/dwalker.xyz/Pages/Error.cshtml.cs new file mode 100644 index 0000000..b7e3274 --- /dev/null +++ b/dwalker.xyz/Pages/Error.cshtml.cs @@ -0,0 +1,20 @@ +using System.Diagnostics; +using Microsoft.AspNetCore.Mvc; +using Microsoft.AspNetCore.Mvc.RazorPages; + +namespace dwalker.xyz.Pages; + +[ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)] +[IgnoreAntiforgeryToken] +public class ErrorModel : PageModel +{ + public string? RequestId { get; set; } + + public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); + + public void OnGet() + { + RequestId = Activity.Current?.Id ?? HttpContext.TraceIdentifier; + } +} + diff --git a/dwalker.xyz/Pages/Index.cshtml b/dwalker.xyz/Pages/Index.cshtml new file mode 100644 index 0000000..0283f0d --- /dev/null +++ b/dwalker.xyz/Pages/Index.cshtml @@ -0,0 +1,11 @@ +@page +@model IndexModel +@{ + ViewData["Title"] = "dwalker.xyz"; +} + +
+

.NET 10 Razor Pages

+

Blank, modern, and ready.

+

A minimal starting point for building dwalker.xyz without demo content or extra scaffolding.

+
diff --git a/dwalker.xyz/Pages/Index.cshtml.cs b/dwalker.xyz/Pages/Index.cshtml.cs new file mode 100644 index 0000000..69ef63d --- /dev/null +++ b/dwalker.xyz/Pages/Index.cshtml.cs @@ -0,0 +1,10 @@ +using Microsoft.AspNetCore.Mvc.RazorPages; + +namespace dwalker.xyz.Pages; + +public class IndexModel : PageModel +{ + public void OnGet() + { + } +} diff --git a/dwalker.xyz/Pages/Shared/_Layout.cshtml b/dwalker.xyz/Pages/Shared/_Layout.cshtml new file mode 100644 index 0000000..52b617a --- /dev/null +++ b/dwalker.xyz/Pages/Shared/_Layout.cshtml @@ -0,0 +1,16 @@ + + + + + + @ViewData["Title"] + + + +
+ @RenderBody() +
+ + @await RenderSectionAsync("Scripts", required: false) + + diff --git a/dwalker.xyz/Pages/_ViewImports.cshtml b/dwalker.xyz/Pages/_ViewImports.cshtml new file mode 100644 index 0000000..874bfd3 --- /dev/null +++ b/dwalker.xyz/Pages/_ViewImports.cshtml @@ -0,0 +1,3 @@ +@using dwalker.xyz +@namespace dwalker.xyz.Pages +@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers diff --git a/dwalker.xyz/Pages/_ViewStart.cshtml b/dwalker.xyz/Pages/_ViewStart.cshtml new file mode 100644 index 0000000..a5f1004 --- /dev/null +++ b/dwalker.xyz/Pages/_ViewStart.cshtml @@ -0,0 +1,3 @@ +@{ + Layout = "_Layout"; +} -- cgit v1.2.3