skip to main content
code

typescript typing practice

the thread through every rung

a bus timetable

20 rungs

0 of 20start
  1. 01 · say something

    calling a function

    first time you type" ( ) . ;

  2. 02 · a name with a type on it

    an annotation

    first time you type, : =

  3. 03 · a shape of its own

    an interface

    first time you type{ }

  4. 04 · a part that might not be there

    an optional field

    first time you type?

  5. 05 · one of a few

    a union of exact values

    first time you type|

  6. 06 · a list of shapes

    an array with a type

    first time you type[ ]

  7. 07 · a note to yourself

    a comment, and arithmetic

    first time you type* + - /

  8. 08 · a choice

    if and else

    first time you type>

  9. 09 · a name for a job, typed

    what goes in and what comes out

    first time you type<

  10. 10 · go through them

    a loop over a typed list

    nothing new to reach for

  11. 11 · words with values in them

    a template string

    first time you type$ `

  12. 12 · is it the same?

    equality, and its opposite

    first time you type!

  13. 13 · make a new list from an old one

    map

    first time you type'

  14. 14 · keep only some of them

    filter, and two conditions

    first time you type&

  15. 15 · when there is nothing there

    a fallback for a missing part

    nothing new to reach for

  16. 16 · a quote inside a quote

    the other quote mark

    nothing new to reach for

  17. 17 · every other hour

    the remainder, and a counting loop

    first time you type%

  18. 18 · a shape that works for anything

    a type left blank until used

    nothing new to reach for

  19. 19 · narrowing a union

    the type decides the answer

    nothing new to reach for

  20. 20 · the whole thing

    everything so far, doing one job

    nothing new to reach for