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
Saucy Dark
colors Workbench UI color keys from the theme JSON colors map.
key HEX RGB RGBA activityBar.background
#3B004A RGB(59, 0, 74) RGBA(59, 0, 74, 1) activityBar.foreground
#FFD84D RGB(255, 216, 77) RGBA(255, 216, 77, 1) activityBarBadge.background
#D4B300 RGB(212, 179, 0) RGBA(212, 179, 0, 1) editor.background
#2B0033 RGB(43, 0, 51) RGBA(43, 0, 51, 1) editor.foreground
#FDFDFD RGB(253, 253, 253) RGBA(253, 253, 253, 1) editor.inactiveSelectionBackground
#FFD63322 RGB(255, 214, 51) RGBA(255, 214, 51, 0.133) editor.selectionBackground
#FFD63344 RGB(255, 214, 51) RGBA(255, 214, 51, 0.267) editorCursor.foreground
#020201 RGB(2, 2, 1) RGBA(2, 2, 1, 1) editorLineNumber.foreground
#AA73FF RGB(170, 115, 255) RGBA(170, 115, 255, 1) sideBar.background
#1F0026 RGB(31, 0, 38) RGBA(31, 0, 38, 1) sideBar.foreground
#D9B3FF RGB(217, 179, 255) RGBA(217, 179, 255, 1) sideBarSectionHeader.background
#3B0052 RGB(59, 0, 82) RGBA(59, 0, 82, 1) sideBarSectionHeader.foreground
#FFD84D RGB(255, 216, 77) RGBA(255, 216, 77, 1) sideBarTitle.foreground
#CFA5FF RGB(207, 165, 255) RGBA(207, 165, 255, 1) statusBar.background
#4C006A RGB(76, 0, 106) RGBA(76, 0, 106, 1) titleBar.activeBackground
#3B0052 RGB(59, 0, 82) RGBA(59, 0, 82, 1) titleBar.activeForeground
#FFE97F RGB(255, 233, 127) RGBA(255, 233, 127, 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
#A85DFF RGB(168, 93, 255) RGBA(168, 93, 255, 1) comment.block
#A85DFF RGB(168, 93, 255) RGBA(168, 93, 255, 1) comment.block.documentation
#A85DFF RGB(168, 93, 255) RGBA(168, 93, 255, 1) comment.line
#A85DFF RGB(168, 93, 255) RGBA(168, 93, 255, 1) constant
#FFB347 RGB(255, 179, 71) RGBA(255, 179, 71, 1) constant.numeric
#FFB347 RGB(255, 179, 71) RGBA(255, 179, 71, 1) constant.numeric.integer
#FFB347 RGB(255, 179, 71) RGBA(255, 179, 71, 1) constant.numeric.float
#FFB347 RGB(255, 179, 71) RGBA(255, 179, 71, 1) constant.numeric.hex
#FFB347 RGB(255, 179, 71) RGBA(255, 179, 71, 1) constant.numeric.octal
#FFB347 RGB(255, 179, 71) RGBA(255, 179, 71, 1) constant.other
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) constant.other.placeholder
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1) entity
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1) entity.name
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.class
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.function
#FFDD66 RGB(255, 221, 102) RGBA(255, 221, 102, 1) entity.name.method
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.namespace
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.section
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.selector
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.tag
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.type
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.type.enum
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.type.interface
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.name.type.struct
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) entity.other
#FF99CC RGB(255, 153, 204) RGBA(255, 153, 204, 1) entity.other.attribute-name
#FF99CC RGB(255, 153, 204) RGBA(255, 153, 204, 1) invalid
#FF0033 RGB(255, 0, 51) RGBA(255, 0, 51, 1) invalid.deprecated
#FF0033 RGB(255, 0, 51) RGBA(255, 0, 51, 1) invalid.illegal
#FF0033 RGB(255, 0, 51) RGBA(255, 0, 51, 1) keyword
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) keyword.control
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) keyword.control.flow
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) keyword.operator
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) keyword.operator.new
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) keyword.operator.assignment
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) keyword.operator.arithmetic
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) keyword.operator.logical
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) keyword.other
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) markup
#FF80DF RGB(255, 128, 223) RGBA(255, 128, 223, 1) markup.bold
#FF80DF RGB(255, 128, 223) RGBA(255, 128, 223, 1) markup.italic
#FF80DF RGB(255, 128, 223) RGBA(255, 128, 223, 1) meta
#D6B3FF RGB(214, 179, 255) RGBA(214, 179, 255, 1) meta.function-call
#FFDD66 RGB(255, 221, 102) RGBA(255, 221, 102, 1) meta.tag
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) punctuation.definition.bracket
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) punctuation.definition.comment
#A85DFF RGB(168, 93, 255) RGBA(168, 93, 255, 1) punctuation.definition.string.begin
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) punctuation.definition.string.end
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) punctuation.separator
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) punctuation.separator.continuation
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) punctuation.terminator
#C770FF RGB(199, 112, 255) RGBA(199, 112, 255, 1) storage
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) storage.modifier
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) storage.type
#E6B800 RGB(230, 184, 0) RGBA(230, 184, 0, 1) string
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.interpolated
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.other
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.quoted
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.quoted.double
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.quoted.other
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.quoted.single
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.quoted.triple
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.regexp
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.template
#D8BF5A RGB(216, 191, 90) RGBA(216, 191, 90, 1) string.unquoted
#D6B3FF RGB(214, 179, 255) RGBA(214, 179, 255, 1) support
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) support.class
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) support.type
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) support.type.primitive
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) support.type.property-name
#D1A3FF RGB(209, 163, 255) RGBA(209, 163, 255, 1) variable
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1) variable.function
#FFDD66 RGB(255, 221, 102) RGBA(255, 221, 102, 1) variable.language
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1) variable.name
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1) variable.other
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1) variable.other.constant
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1) variable.other.property
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1) variable.other.readwrite
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1) variable.parameter
#FF66CC RGB(255, 102, 204) RGBA(255, 102, 204, 1)