# System.Web.WebPages

**Kind:** Service

**Source:** `Pams/Logic/Pams.Business/Pams.Business.csproj` (line 1)

**Part of:** [Pams](subsystem-pams)

NuGet package dependency

`System.Web.WebPages` is a NuGet package dependency declared in `Pams.Business.csproj`. It supports legacy ASP.NET Web Pages components that may be required by code or transitive dependencies in the Pams business project.

## Diagram

```mermaid
sequenceDiagram
    participant Build as Project Build
    participant Csproj as Pams.Business.csproj
    participant NuGet as NuGet Restore
    participant WebPages as System.Web.WebPages
    participant App as ASP.NET Application

    Build->>Csproj: Read package dependency
    Csproj->>NuGet: Restore System.Web.WebPages
    NuGet->>WebPages: Resolve package assembly
    WebPages->>App: Support legacy Web Pages dependencies
```

## Usage

```ts
// Client code can call an application endpoint backed by legacy ASP.NET components.
async function loadPageContent(path: string): Promise<string> {
  const response = await fetch(path);

  if (!response.ok) {
    throw new Error("Unable to load page content.");
  }

  return response.text();
}

loadPageContent("/legacy/page")
  .then((html) => {
    document.body.innerHTML = html;
  })
  .catch((error) => {
    console.error(error);
  });
```

## AI Coding Instructions

- Treat `System.Web.WebPages` as a legacy NuGet dependency declared by `Pams.Business.csproj`.
- Check for Web Pages, Razor, or ASP.NET dependencies before removing or updating this package.
- Keep package changes compatible with the project’s legacy project-file format.
- Restore NuGet packages after changing package references and verify dependent projects still build.

## Used by

3 references from 3 files. Each is a place in this repository where the symbol is actually used — go read one rather than trusting an example.

### Injected or called by (3)

- `Pams.API` — `Pams/API/Pams.API/Pams.API.csproj`:1
- `Pams.Core` — `Pams/Core/Pams.Core/Pams.Core.csproj`:1
- `Pams.Business` — `Pams/Logic/Pams.Business/Pams.Business.csproj`:1
