Skip to content

Commit 9e3596c

Browse files
authored
Mark 6.0 as supported, drop 5.2 (#1269)
1 parent 3f6f35d commit 9e3596c

6 files changed

Lines changed: 23 additions & 28 deletions

File tree

.changeset/pretty-groups-camp.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"@definitelytyped/typescript-packages": patch
3+
"@definitelytyped/typescript-versions": patch
4+
---
5+
6+
Mark 6.0 as supported, drop 5.2

packages/publisher/test/__snapshots__/generate-packages.test.ts.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ exports[`basicPackageJson 1`] = `
5757
"@types/express": "*"
5858
},
5959
"typesPublisherContentHash": "53300522250468c4161b10d962cac2d9d8f2cfee1b3dfef4b749a7c3ec839275",
60-
"typeScriptVersion": "5.2"
60+
"typeScriptVersion": "5.3"
6161
}"
6262
`;
6363

packages/typescript-packages/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@
2222
},
2323
"dependencies": {
2424
"@definitelytyped/typescript-versions": "workspace:*",
25-
"typescript-5.2": "npm:typescript@~5.2.0-0",
2625
"typescript-5.3": "npm:typescript@~5.3.0-0",
2726
"typescript-5.4": "npm:typescript@~5.4.0-0",
2827
"typescript-5.5": "npm:typescript@~5.5.0-0",

packages/typescript-versions/src/index.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,9 @@ export type AllTypeScriptVersion = UnsupportedTypeScriptVersion | TypeScriptVers
4141

4242
export namespace TypeScriptVersion {
4343
/** Add to this list when a version actually ships. */
44-
export const shipped = ["5.2", "5.3", "5.4", "5.5", "5.6", "5.7", "5.8", "5.9"] as const;
44+
export const shipped = ["5.3", "5.4", "5.5", "5.6", "5.7", "5.8", "5.9", "6.0"] as const;
4545
/** Add to this list when a version is available as typescript@next */
46-
export const supported = [...shipped, "6.0"] as const;
46+
export const supported = [...shipped] as const;
4747
/** Add to this list when it will no longer be supported on Definitely Typed */
4848
export const unsupported = [
4949
"2.0",
@@ -78,6 +78,7 @@ export namespace TypeScriptVersion {
7878
"4.9",
7979
"5.0",
8080
"5.1",
81+
"5.2",
8182
] as const;
8283
export const all: readonly AllTypeScriptVersion[] = [...unsupported, ...supported];
8384
export const lowest = supported[0];

packages/typescript-versions/test/index.test.ts

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ describe("isSupported", () => {
2020
it("works", () => {
2121
expect(TypeScriptVersion.isSupported("5.6")).toBeTruthy();
2222
});
23-
it("supports 5.2", () => {
24-
expect(TypeScriptVersion.isSupported("5.2")).toBeTruthy();
23+
it("supports 5.3", () => {
24+
expect(TypeScriptVersion.isSupported("5.3")).toBeTruthy();
2525
});
2626
it("does not support 4.0", () => {
2727
expect(!TypeScriptVersion.isSupported("4.0")).toBeTruthy();
@@ -30,7 +30,7 @@ describe("isSupported", () => {
3030

3131
describe("isTypeScriptVersion", () => {
3232
it("accepts in-range", () => {
33-
expect(TypeScriptVersion.isTypeScriptVersion("5.2")).toBeTruthy();
33+
expect(TypeScriptVersion.isTypeScriptVersion("5.3")).toBeTruthy();
3434
});
3535
it("rejects out-of-range", () => {
3636
expect(TypeScriptVersion.isTypeScriptVersion("101.1")).toBeFalsy();
@@ -42,17 +42,16 @@ describe("isTypeScriptVersion", () => {
4242

4343
describe("range", () => {
4444
it("works", () => {
45-
expect(TypeScriptVersion.range("5.2")).toEqual(["5.2", "5.3", "5.4", "5.5", "5.6", "5.7", "5.8", "5.9", "6.0"]);
45+
expect(TypeScriptVersion.range("5.3")).toEqual(["5.3", "5.4", "5.5", "5.6", "5.7", "5.8", "5.9", "6.0"]);
4646
});
47-
it("includes 5.2 onwards", () => {
48-
expect(TypeScriptVersion.range("5.2")).toEqual(TypeScriptVersion.supported);
47+
it("includes 5.3 onwards", () => {
48+
expect(TypeScriptVersion.range("5.3")).toEqual(TypeScriptVersion.supported);
4949
});
5050
});
5151

5252
describe("tagsToUpdate", () => {
5353
it("works", () => {
54-
expect(TypeScriptVersion.tagsToUpdate("5.2")).toEqual([
55-
"ts5.2",
54+
expect(TypeScriptVersion.tagsToUpdate("5.3")).toEqual([
5655
"ts5.3",
5756
"ts5.4",
5857
"ts5.5",
@@ -64,8 +63,8 @@ describe("tagsToUpdate", () => {
6463
"latest",
6564
]);
6665
});
67-
it("allows 5.2 onwards", () => {
68-
expect(TypeScriptVersion.tagsToUpdate("5.2")).toEqual(
66+
it("allows 5.3 onwards", () => {
67+
expect(TypeScriptVersion.tagsToUpdate("5.3")).toEqual(
6968
TypeScriptVersion.supported.map((s) => "ts" + s).concat("latest"),
7069
);
7170
});

pnpm-lock.yaml

Lines changed: 4 additions & 14 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)