Modifiers of the Types
A Learning TypeScript > Type Modifiers 🥗 appetizer project. You'll practice using type modifiers to inform TypeScript's understanding of code.
Greetings, my fearless friend! My companions and I are a group of powerful beings tasked with safeguarding the safety of this realm and many others. Using the power revealed to by Castle TypeScript, we have seen the plots of my evil nemesis, Skeletype! Together we defend the universe and must stop those plots from becoming a reality!
We must gather our friends and gain understanding of our enemy. These small projects will help us learn the lay of the land and gain the upper hand in the inevitable battle. Please, join us!
Setup
If you haven't yet, set up the github.com/LearningTypeScript/projects repository locally.
shellgit clone https://github.com/LearningTypeScript/projects learning-typescript-projectscd learning-typescript-projectsnpm i
shellgit clone https://github.com/LearningTypeScript/projects learning-typescript-projectscd learning-typescript-projectsnpm i
Open your editor in this project's directory:
shellcode projects/type-modifiers/modifiers-of-the-types
shellcode projects/type-modifiers/modifiers-of-the-types
In one terminal, run the TypeScript compiler via the tsc script within whichever step you're working on.
For example, to start the TypeScript compiler on the first step in watch mode:
shellnpm run tsc -- --project 01-fabulous-secret-powers --watch
shellnpm run tsc -- --project 01-fabulous-secret-powers --watch
In another terminal, run Jest via the test script on whichever step you're working on.
For example, to start tests for the first step in watch mode:
shellnpm run test -- 1 --watch
shellnpm run test -- 1 --watch
Note: your terminal should be in the
modifiers-of-the-typesdirectory, not the root repository's directory.
Steps
Notes
- Don't import code from one step into another.