Skip to content

Integrate api-extractor and leverage @internal to protect certain functions #1686

Description

@TwitchBronBron

There are many functions in our typescript source code that are used "internally" in the project, so they are marked as public. However, we don't intend for public consumers to leverage these. Our current options are just public or private. and if we use private but still want to call them then we need to use the indexing pattern myClass['somePrivateFunction'].

Microsoft provides a tool called api-extractor that supports the @internal jsdoc annotation to strip those from our exported type definitions.

Integrate that tool, and do a pass to hide certain functions that we don't intend for public consumption.

This is not technically a breaking change because the functions themselves are still present, so existing code will still work. But their typescript builds will start failing at compile time. Need to think on that, but I think we should do it in v0 anyway.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions