beginners-typescript-tutorial
beginners-typescript-tutorial copied to clipboard
An interactive TypeScript tutorial for beginners
On Windows, the command prompt will choke when you set and use environment variables like `SOLUTION=true`, so to fix this I installed the **cross-env** package, which makes it so you...
### Changes - Fixed typo in `11-record.problem` and `11-record.solutions` to -> from - Cleaned up `Promise` and `string` types from `18-function-types-with-promises.solution` because they are inferred. Slight difference is that we...
add a solution for set question (10-set.problem.ts)
I have node vs 21.0.0 installed. After CD in to SRC directory and running the following alias command: `npm run e 01` I get the following error in the console:...
Getting the following error after running any exercise (tests are passing) inside VS Code : `Checking types... error TS5023: Unknown compiler option '-'. Failed. Try again!`
Small change that makes a huge difference for Stackblitz and somewhat improvements for local: ## Local Before:  After:  ## Stackblitz Before:  After:  Those were run in...
..... ``` interface User { id: string; firstName: string; lastName: string; } interface Post { id: User["id"]; title: string; body: string; } interface Comment { id: User["id"]; comment: string; }...
I came up with a slightly different solution to problem 15-intersection which follows from problem 14-extends. ```typescript interface UserWithPosts extends User { posts: Post[] } ``` This interface also passes...
The 3rd solution gives me the error on the TypeScript playground as well.
Hi! In the spirit of providing alternate solutions for exercice 13 (entitled [`catch-blocks`](https://github.com/total-typescript/beginners-typescript-tutorial/blob/3b55248a9f268c9777485453f4de5d20fce080cd/src/13-catch-blocks.problem.ts)), does it make sense to encourage possible introduction of - [`unknown` type](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-0.html#new-unknown-top-type) - guard clause for case...