Skip to content

Add @internal JSDoc tags to generated *Impl and *PromiseImpl classes #15902

@davidfowl

Description

@davidfowl

Summary

The generated .modules/aspire.ts file contains both public API interfaces (e.g. RedisResource, RedisResourcePromise) and internal implementation classes (e.g. RedisResourceImpl, RedisResourcePromiseImpl). The implementation classes are not exported but still show up in editor autocomplete suggestions and hover tooltips when navigating the file.

Proposal

Add /** @internal */ JSDoc tags to all generated *Impl and *PromiseImpl classes in AtsTypeScriptCodeGenerator.cs. This tells TypeScript tooling to deprioritize or hide these symbols from autocomplete and API documentation.

Context

The generated aspire.ts file is ~46K lines / 3.9MB with ~125 internal classes and 52 Promise interfaces. The public API surface is ~206 exports. Adding @internal tags helps editors focus on the public API without requiring a .d.ts split.

Implementation

In AtsTypeScriptCodeGenerator.cs, prefix each class *Impl and class *PromiseImpl declaration with:

/** @internal */
class RedisResourceImpl ...

The *PromiseImpl classes already have some @internal tags on their methods but the class declarations themselves need it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-polyglotIssues related to polyglot apphosts

    Type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions