Skip to content

Microsoft.Web.Infrastructure

reference
1 min readUpdated

Kind: Service

Source: Pams/Core/Pams.Security/Pams.Security.csproj (line 1)

Part of: Pams

NuGet package dependency

Microsoft.Web.Infrastructure is a NuGet package dependency declared by Pams.Security.csproj. It supplies ASP.NET web infrastructure types that the .NET application loads during build and runtime; JavaScript clients do not import this package directly.

Diagram

mermaid
sequenceDiagram
    participant Build as Build Process
    participant Security as Pams.Security.csproj
    participant NuGet as NuGet Restore
    participant WebApp as ASP.NET Application

    Build->>Security: Read package dependency
    Security->>NuGet: Resolve Microsoft.Web.Infrastructure
    NuGet-->>Security: Restore package assembly
    Security->>WebApp: Load dependency at runtime

Usage

ts
import { readFile } from "node:fs/promises";

const projectPath = "Pams/Core/Pams.Security/Pams.Security.csproj";
const projectFile = await readFile(projectPath, "utf8");

if (!projectFile.includes("Microsoft.Web.Infrastructure")) {
  throw new Error(
    "Microsoft.Web.Infrastructure is missing from Pams.Security.csproj",
  );
}

console.log("Microsoft.Web.Infrastructure dependency is declared.");

AI Coding Instructions

  • Keep the Microsoft.Web.Infrastructure dependency declaration compatible with the existing legacy project format.
  • Restore NuGet packages before building projects that reference Pams.Security.
  • Do not import this package from TypeScript or JavaScript; it is loaded by the .NET application.
  • Check ASP.NET module registration and application startup code before removing or replacing this dependency.

Was this page helpful?

Download as PDF
Microsoft.Web.Infrastructure — PAMS Documentation Test