Skip to content

Commit

Permalink
Updated to TS 5.1
Browse files Browse the repository at this point in the history
  • Loading branch information
mattpocock committed Jun 5, 2023
1 parent 3b2647f commit c70bbbc
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 20 deletions.
16 changes: 8 additions & 8 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"cross-fetch": "^3.1.5",
"jsdom": "^21.1.1",
"prettier": "^2.8.7",
"typescript": "^5.0.3",
"typescript": "^5.1.3",
"vite-tsconfig-paths": "^4.0.7",
"vitest": "^0.31.1"
},
Expand Down Expand Up @@ -106,4 +106,4 @@
"ts-toolbelt": "^9.6.0",
"zod": "^3.19.1"
}
}
}
10 changes: 0 additions & 10 deletions scripts/tests/__snapshots__/all.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,11 @@ src/01-branded-types/06-index-signatures.problem.ts(59,3): error TS2578: Unused
src/02-globals/07-add-function-to-global-scope.problem.ts(20,12): error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature.
src/02-globals/07-add-function-to-global-scope.problem.ts(21,12): error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature.
src/02-globals/07-add-function-to-global-scope.problem.ts(24,10): error TS2304: Cannot find name 'myFunc'.
src/02-globals/07-add-function-to-global-scope.problem.ts(25,23): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/02-globals/07-add-function-to-global-scope.problem.ts(25,36): error TS2304: Cannot find name 'myFunc'.
src/02-globals/07-add-function-to-global-scope.problem.ts(29,10): error TS2304: Cannot find name 'myVar'.
src/02-globals/07-add-function-to-global-scope.problem.ts(30,23): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/02-globals/07-add-function-to-global-scope.problem.ts(30,36): error TS2304: Cannot find name 'myVar'.
src/02-globals/08-add-to-window.problem.ts(13,8): error TS2339: Property 'makeGreeting' does not exist on type 'Window & typeof globalThis'.
src/02-globals/08-add-to-window.problem.ts(16,17): error TS2339: Property 'makeGreeting' does not exist on type 'Window & typeof globalThis'.
src/02-globals/08-add-to-window.problem.ts(18,23): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/02-globals/08-add-to-window.problem.ts(18,43): error TS2339: Property 'makeGreeting' does not exist on type 'Window & typeof globalThis'.
src/02-globals/09-adding-to-process-env.problem.ts(23,24): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/02-globals/10-event-dispatcher.problem.1.ts(36,19): error TS2322: Type '\\"LOG_OUT\\"' is not assignable to type '\\"LOG_IN\\"'.
Expand All @@ -49,7 +46,6 @@ src/03-type-predicates-assertion-functions/15-type-predicates-with-generics.prob
src/03-type-predicates-assertion-functions/16-brands-and-type-predicates.problem.ts(35,23): error TS2345: Argument of type 'PasswordValues' is not assignable to parameter of type 'Valid<PasswordValues>'.
src/03-type-predicates-assertion-functions/17-brands-and-assertion-functions.problem.ts(34,21): error TS2345: Argument of type 'PasswordValues' is not assignable to parameter of type 'Valid<PasswordValues>'.
src/04-classes/17.8-classes-as-types-and-value.problem.ts(12,17): error TS18046: 'error' is of type 'unknown'.
src/04-classes/17.8-classes-as-types-and-value.problem.ts(14,22): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/04-classes/17.8-classes-as-types-and-value.problem.ts(14,35): error TS18046: 'error' is of type 'unknown'.
src/04-classes/18-type-predicates-and-classes.problem.ts(41,23): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/04-classes/18.2-assertion-functions-and-classes.problem.ts(26,25): error TS2344: Type 'false' does not satisfy the constraint 'true'.
Expand Down Expand Up @@ -89,13 +85,9 @@ src/06-identity-functions/30.5-reverse-mapped-types.problem.ts(8,11): error TS70
src/06-identity-functions/30.5-reverse-mapped-types.problem.ts(11,24): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/06-identity-functions/30.5-reverse-mapped-types.problem.ts(13,11): error TS7006: Parameter 'name' implicitly has an 'any' type.
src/06-identity-functions/30.5-reverse-mapped-types.problem.ts(16,24): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/07-challenges/31-merge-dynamic-object-with-global.problem.ts(13,10): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/07-challenges/31-merge-dynamic-object-with-global.problem.ts(13,30): error TS2339: Property 'add' does not exist on type 'Window & typeof globalThis'.
src/07-challenges/31-merge-dynamic-object-with-global.problem.ts(14,10): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/07-challenges/31-merge-dynamic-object-with-global.problem.ts(14,30): error TS2339: Property 'subtract' does not exist on type 'Window & typeof globalThis'.
src/07-challenges/31-merge-dynamic-object-with-global.problem.ts(15,10): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/07-challenges/31-merge-dynamic-object-with-global.problem.ts(15,30): error TS2339: Property 'multiply' does not exist on type 'Window & typeof globalThis'.
src/07-challenges/31-merge-dynamic-object-with-global.problem.ts(16,10): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/07-challenges/31-merge-dynamic-object-with-global.problem.ts(16,30): error TS2339: Property 'divide' does not exist on type 'Window & typeof globalThis'.
src/07-challenges/32-narrow-with-arrays.problem.ts(10,35): error TS18046: 'fruit' is of type 'unknown'.
src/07-challenges/32-narrow-with-arrays.problem.ts(31,1): error TS2578: Unused '@ts-expect-error' directive.
Expand All @@ -112,8 +104,6 @@ src/07-challenges/34-dynamic-reducer.problem.ts(52,36): error TS2558: Expected 0
src/07-challenges/34-dynamic-reducer.problem.ts(55,5): error TS2345: Argument of type '(state: unknown, action: { username: string; password: string; }) => { username: string; password: string; }' is not assignable to parameter of type '(state: unknown, payload: unknown) => unknown'.
Types of parameters 'action' and 'payload' are incompatible.
Type 'unknown' is not assignable to type '{ username: string; password: string; }'.
src/07-challenges/34-dynamic-reducer.problem.ts(75,23): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/07-challenges/34-dynamic-reducer.problem.ts(86,23): error TS2344: Type 'false' does not satisfy the constraint 'true'.
src/07-challenges/34-dynamic-reducer.problem.ts(95,7): error TS2578: Unused '@ts-expect-error' directive.
src/07-challenges/34-dynamic-reducer.problem.ts(104,5): error TS2578: Unused '@ts-expect-error' directive.
src/07-challenges/38-challenge-custom-jsx-element.problem.tsx(13,17): error TS2339: Property 'custom-element' does not exist on type 'JSX.IntrinsicElements'.
Expand Down

0 comments on commit c70bbbc

Please sign in to comment.