ts-expose-internals

Augment the TypeScript compiler module's types to expose hidden internal types

MIT 85 个版本
安装
npm install ts-expose-internals
yarn add ts-expose-internals
pnpm add ts-expose-internals
bun add ts-expose-internals
README

License

TypeScript Internal Types

Expose TypeScript internal types by simply adding a development dependency.

Setup

  1. Add aliased dependency to package.json (use the same version as your typescript version)

    {
      "devDependencies": {
        "typescript": "^5.1.3",
        // Note: The package is 'ts-expose-internals', but we are aliasing within the @types scope to make TS adopt it globally
        "@types/ts-expose-internals": "npm:ts-expose-internals@5.1.3"
      }
    }
    
  2. Run npm install / yarn install

Usage

All internal types are now available within the primary typescript module

// This namespace is flagged @internal and is omitted from published types, but now we can access it!
import { JsDoc } from 'typescript'

How It Works

The code within this repo runs on a schedule of once per day via GitHub Actions.

It checks for new TypeScript release tags, and if there are any, it clones the source code for that release and builds the internal types. After, it performs a bit of transformation magic and publishes the package to NPM.

New types are added to the 'typescript' module via the Module Augmentation technique.

Notes

  • We publish for full TS releases only. If you'd like nightly builds, have a look at byots.
  • If we don't have a package for the latest release, please allow 24hrs, then file an issue.

Acknowledgments

Thanks to basarat for his work on byots, which served as the inspiration!

版本列表
5.6.3 2024-10-10
5.6.2 2024-09-10
5.6.1-rc 2024-08-24
5.6.0-beta 2024-07-27
5.5.4 2024-07-23
5.5.3 2024-07-02
5.5.2 2024-06-21
5.5.1-rc 2024-06-08
5.4.5 2024-04-11
5.4.4 2024-04-05
5.4.3 2024-03-21
5.4.2 2024-03-07
5.4.1-rc 2024-02-23
5.4.0-beta 2024-01-30
5.3.3 2023-12-07
5.3.2 2023-11-21
5.3.1-rc 2023-11-04
5.3.0-beta 2023-10-30
5.2.2 2023-08-26
5.2.1-rc 2023-08-10
5.2.0-beta 2023-07-06
5.1.6 2023-07-06
5.1.5 2023-06-28
5.1.3 2023-06-21
5.1.1-rc 2023-06-21
5.1.0-beta 2023-06-21
5.0.4 2023-06-21
5.0.3 2023-06-21
5.0.2 2023-06-21
4.9.5 2023-01-31
4.9.4 2022-12-08
4.9.3 2022-11-17
4.9.0-rc 2023-03-17
4.9.0-beta 2023-03-17
4.8.4 2022-09-28
4.8.3 2022-09-08
4.8.2 2022-08-26
4.8.0-rc 2022-08-11
4.8.0-beta 2022-06-22
4.7.4 2022-06-17
4.7.3 2022-06-03
4.7.2 2022-05-27
4.7.0-rc 2022-05-27
4.7.0-beta 2022-05-06
4.6.4 2022-05-06
4.6.3 2022-05-06
4.6.2 2022-05-06
4.6.0-beta 2022-01-27
4.5.5 2022-01-21
4.5.4 2021-12-14
4.5.3 2021-12-11
4.5.2 2021-11-17
4.5.0-rc 2021-11-03
4.5.0-beta 2021-10-02
4.4.4 2021-10-12
4.4.3 2021-09-11
4.4.2 2021-08-27
4.4.0-rc 2021-08-13
4.3.2 2021-05-27
4.3.0-rc 2021-05-27
4.3.0-beta 2021-04-10
4.2.4 2021-04-10
4.2.3 2021-03-13
4.2.2 2021-03-13
4.2.0-rc 2021-03-13
4.2.0-beta 2021-01-21
4.1.5 2021-03-13
4.1.4 2021-03-13
4.1.3 2020-12-15
4.1.2 2020-11-23
4.1.0-rc 2020-11-23
4.1.0-beta 2020-09-19
4.0.7 2021-03-13
4.0.6 2021-03-13
4.0.5 2020-10-28
4.0.3 2020-09-19
4.0.2 2020-08-21
4.0.0-rc 2020-09-19
4.0.0-beta 2020-07-25
3.9.7 2020-07-25
3.9.7-patch 2020-07-28
3.9.6 2020-07-25
3.8.3 2020-07-25
3.8.2 2020-07-25
3.8.0-rc 2020-07-25