Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/phryneas/ts-version
A little utility type package that allows you to access the current TypeScript version from your types.
https://github.com/phryneas/ts-version
library
Last synced: 15 days ago
JSON representation
A little utility type package that allows you to access the current TypeScript version from your types.
- Host: GitHub
- URL: https://github.com/phryneas/ts-version
- Owner: phryneas
- License: mit
- Created: 2022-08-05T09:01:06.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-08-05T12:26:06.000Z (over 2 years ago)
- Last Synced: 2024-10-04T13:44:30.590Z (about 1 month ago)
- Topics: library
- Language: TypeScript
- Homepage:
- Size: 4.88 KB
- Stars: 16
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# `@phryneas/ts-version`
A little utility type package that allows you to access the current TypeScript version from your types.
```ts
import { TSVersion } from "@phryneas/ts-version";type Version = `${TSVersion.Major}.${TSVersion.Minor}`;
type VersionDependentType = TSVersion.AtLeast<4, 7> extends true
? "we're in the future!"
: "it's the stone age!";
```