VS Code preview Full workbench mockup using this variant's colors and tokenColors.
fetchUser.tssrc/components index.ts README.md
src
components fetchUser.ts Button.tsx Modal.tsx legacy.tsx fetch Config.tsindex.ts renamed.ts staged.ts removed.ts
vendor package.json broken.ts slow.ts tsconfig.json README.md package-lock.json 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
export interface User {
id : string ;
name : string ;
role : "admin" | "member" ;
tags : string [] ;
}
/**
* Fetch user data by ID
* @ param id
* @ returns User object or null if ID is invalid
*/
export async function fetchUser ( id : string ) : Promise < User | null > {
if (! id ) {
return null ;
}
const response = await fetch ( `/api/users/ ${ id } ` , {
method : "GET" ,
headers : { Accept : "application/json" },
} ) ;
if (! response .ok ) {
throw new Error ( `HTTP ${ response .status } ` ) ;
}
return ( await response . json ()) as User ;
}
function greet ( user : User ) : string {
// Simple greeting function that uses the user's name
return `Hello, ${ user .name } !` ;
}
Problems1
Output
Debug Console
Terminal
Ports
✓ fetchUser passed 12 blk
✗ Cannot find name 'user'. error ▲ warning 412 ready localhost
Ln 5, Col 12
Spaces: 2
UTF-8
LF
TypeScript
End of the World
colors Workbench UI color keys from the theme JSON colors map.
key HEX RGB RGBA activityBar.activeFocusBorder
#AF00DB RGB(175, 0, 219) RGBA(175, 0, 219, 1) activityBar.background
#D3D3D3 RGB(211, 211, 211) RGBA(211, 211, 211, 1) activityBar.foreground
#0451A5 RGB(4, 81, 165) RGBA(4, 81, 165, 1) activityBar.inactiveForeground
#0451A570 RGB(4, 81, 165) RGBA(4, 81, 165, 0.439) activityBarBadge.background
#AF00DBB0 RGB(175, 0, 219) RGBA(175, 0, 219, 0.69) activityBarBadge.foreground
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) editor.background
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) editor.foreground
#000000 RGB(0, 0, 0) RGBA(0, 0, 0, 1) editor.inactiveSelectionBackground
#E5EBF1 RGB(229, 235, 241) RGBA(229, 235, 241, 1) editor.selectionHighlightBackground
#ADD6FF80 RGB(173, 214, 255) RGBA(173, 214, 255, 0.502) editorIndentGuide.activeBackground
#939393 RGB(147, 147, 147) RGBA(147, 147, 147, 1) editorIndentGuide.background
#D3D3D3 RGB(211, 211, 211) RGBA(211, 211, 211, 1) editorSuggestWidget.background
#F3F3F3 RGB(243, 243, 243) RGBA(243, 243, 243, 1) input.placeholderForeground
#767676 RGB(118, 118, 118) RGBA(118, 118, 118, 1) list.hoverBackground
#E8E8E8 RGB(232, 232, 232) RGBA(232, 232, 232, 1) searchEditor.textInputBorder
#CECECE RGB(206, 206, 206) RGBA(206, 206, 206, 1) settings.numberInputBorder
#CECECE RGB(206, 206, 206) RGBA(206, 206, 206, 1) settings.textInputBorder
#CECECE RGB(206, 206, 206) RGBA(206, 206, 206, 1) sideBarSectionHeader.background
#00000000 RGB(0, 0, 0) RGBA(0, 0, 0, 0) sideBarSectionHeader.border
#61616130 RGB(97, 97, 97) RGBA(97, 97, 97, 0.188) sideBarTitle.foreground
#6F6F6F RGB(111, 111, 111) RGBA(111, 111, 111, 1) statusBarItem.remoteBackground
#16825D RGB(22, 130, 93) RGBA(22, 130, 93, 1) statusBarItem.remoteForeground
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1)
tokenColors Foregrounds this theme assigns to the token scope catalog. A rule with only a font style is skipped, and a longer matching scope wins. Italic and bold rules are not listed — the preview above shows them in the code.
scope HEX RGB RGBA comment
#008000 RGB(0, 128, 0) RGBA(0, 128, 0, 1) comment.block
#008000 RGB(0, 128, 0) RGBA(0, 128, 0, 1) comment.block.documentation
#008000 RGB(0, 128, 0) RGBA(0, 128, 0, 1) comment.line
#008000 RGB(0, 128, 0) RGBA(0, 128, 0, 1) constant
#FF0000 RGB(255, 0, 0) RGBA(255, 0, 0, 1) constant.character
#0000FF RGB(0, 0, 255) RGBA(0, 0, 255, 1) constant.character.escape
#FF0000 RGB(255, 0, 0) RGBA(255, 0, 0, 1) constant.numeric
#098658 RGB(9, 134, 88) RGBA(9, 134, 88, 1) constant.numeric.integer
#098658 RGB(9, 134, 88) RGBA(9, 134, 88, 1) constant.numeric.float
#098658 RGB(9, 134, 88) RGBA(9, 134, 88, 1) constant.numeric.hex
#098658 RGB(9, 134, 88) RGBA(9, 134, 88, 1) constant.numeric.octal
#098658 RGB(9, 134, 88) RGBA(9, 134, 88, 1) constant.other
#811F3F RGB(129, 31, 63) RGBA(129, 31, 63, 1) constant.regexp
#811F3F RGB(129, 31, 63) RGBA(129, 31, 63, 1) entity
#795E26 RGB(121, 94, 38) RGBA(121, 94, 38, 1) entity.name
#795E26 RGB(121, 94, 38) RGBA(121, 94, 38, 1) entity.name.class
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) entity.name.function
#795E26 RGB(121, 94, 38) RGBA(121, 94, 38, 1) entity.name.namespace
#222222 RGB(34, 34, 34) RGBA(34, 34, 34, 1) entity.name.selector
#800000 RGB(128, 0, 0) RGBA(128, 0, 0, 1) entity.name.tag
#800000 RGB(128, 0, 0) RGBA(128, 0, 0, 1) entity.name.type
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) entity.name.type.enum
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) entity.name.type.interface
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) entity.name.type.struct
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) entity.other
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) entity.other.attribute-name
#FF0000 RGB(255, 0, 0) RGBA(255, 0, 0, 1) entity.other.inherited-class
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) invalid
#CD3131 RGB(205, 49, 49) RGBA(205, 49, 49, 1) invalid.deprecated
#CD3131 RGB(205, 49, 49) RGBA(205, 49, 49, 1) invalid.illegal
#CD3131 RGB(205, 49, 49) RGBA(205, 49, 49, 1) keyword
#0000FF RGB(0, 0, 255) RGBA(0, 0, 255, 1) keyword.control
#AF00DB RGB(175, 0, 219) RGBA(175, 0, 219, 1) keyword.control.flow
#AF00DB RGB(175, 0, 219) RGBA(175, 0, 219, 1) keyword.operator
#000000 RGB(0, 0, 0) RGBA(0, 0, 0, 1) keyword.operator.new
#AF00DB RGB(175, 0, 219) RGBA(175, 0, 219, 1) keyword.operator.assignment
#000000 RGB(0, 0, 0) RGBA(0, 0, 0, 1) keyword.operator.arithmetic
#000000 RGB(0, 0, 0) RGBA(0, 0, 0, 1) keyword.operator.logical
#000000 RGB(0, 0, 0) RGBA(0, 0, 0, 1) keyword.other
#0000FF RGB(0, 0, 255) RGBA(0, 0, 255, 1) markup
#800000 RGB(128, 0, 0) RGBA(128, 0, 0, 1) markup.bold
#000080 RGB(0, 0, 128) RGBA(0, 0, 128, 1) markup.changed
#0451A5 RGB(4, 81, 165) RGBA(4, 81, 165, 1) markup.deleted
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) markup.heading
#800000 RGB(128, 0, 0) RGBA(128, 0, 0, 1) markup.inline.raw
#800000 RGB(128, 0, 0) RGBA(128, 0, 0, 1) markup.inserted
#098658 RGB(9, 134, 88) RGBA(9, 134, 88, 1) meta
#001080 RGB(0, 16, 128) RGBA(0, 16, 128, 1) meta.preprocessor
#0000FF RGB(0, 0, 255) RGBA(0, 0, 255, 1) meta.return-type
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) meta.type
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) punctuation.definition.bracket
#222222 RGB(34, 34, 34) RGBA(34, 34, 34, 1) punctuation.definition.comment
#008000 RGB(0, 128, 0) RGBA(0, 128, 0, 1) punctuation.definition.string.begin
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) punctuation.definition.string.end
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) punctuation.separator
#222222 RGB(34, 34, 34) RGBA(34, 34, 34, 1) punctuation.separator.continuation
#222222 RGB(34, 34, 34) RGBA(34, 34, 34, 1) punctuation.terminator
#222222 RGB(34, 34, 34) RGBA(34, 34, 34, 1) storage
#0000FF RGB(0, 0, 255) RGBA(0, 0, 255, 1) storage.modifier
#0000FF RGB(0, 0, 255) RGBA(0, 0, 255, 1) storage.type
#0000FF RGB(0, 0, 255) RGBA(0, 0, 255, 1) string
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) string.interpolated
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) string.other
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) string.quoted
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) string.quoted.double
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) string.quoted.other
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) string.quoted.single
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) string.quoted.triple
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) string.regexp
#811F3F RGB(129, 31, 63) RGBA(129, 31, 63, 1) string.template
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) string.unquoted
#A31515 RGB(163, 21, 21) RGBA(163, 21, 21, 1) support
#808080 RGB(128, 128, 128) RGBA(128, 128, 128, 1) support.class
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) support.constant
#0451A5 RGB(4, 81, 165) RGBA(4, 81, 165, 1) support.function
#795E26 RGB(121, 94, 38) RGBA(121, 94, 38, 1) support.other
#808080 RGB(128, 128, 128) RGBA(128, 128, 128, 1) support.type
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) support.type.primitive
#267F99 RGB(38, 127, 153) RGBA(38, 127, 153, 1) support.type.property-name
#FF0000 RGB(255, 0, 0) RGBA(255, 0, 0, 1) support.variable
#001080 RGB(0, 16, 128) RGBA(0, 16, 128, 1) variable
#001080 RGB(0, 16, 128) RGBA(0, 16, 128, 1) variable.function
#001080 RGB(0, 16, 128) RGBA(0, 16, 128, 1) variable.language
#0000FF RGB(0, 0, 255) RGBA(0, 0, 255, 1) variable.name
#001080 RGB(0, 16, 128) RGBA(0, 16, 128, 1) variable.other
#001080 RGB(0, 16, 128) RGBA(0, 16, 128, 1) variable.other.constant
#222222 RGB(34, 34, 34) RGBA(34, 34, 34, 1) variable.other.property
#222222 RGB(34, 34, 34) RGBA(34, 34, 34, 1) variable.other.readwrite
#001080 RGB(0, 16, 128) RGBA(0, 16, 128, 1) variable.parameter
#001080 RGB(0, 16, 128) RGBA(0, 16, 128, 1)