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
TruBoo
colors Workbench UI color keys from the theme JSON colors map.
key HEX RGB RGBA editor.background
#1B2B34 RGB(27, 43, 52) RGBA(27, 43, 52, 1) editor.foreground
#CDD3DE RGB(205, 211, 222) RGBA(205, 211, 222, 1) editor.lineHighlightBackground
#00000030 RGB(0, 0, 0) RGBA(0, 0, 0, 0.188) editor.selectionBackground
#4F5B66 RGB(79, 91, 102) RGBA(79, 91, 102, 1) editorCursor.foreground
#FFCC00 RGB(255, 204, 0) RGBA(255, 204, 0, 1) editorGroupHeader.tabsBorder
#E74C3C RGB(231, 76, 60) RGBA(231, 76, 60, 1) editorWhitespace.foreground
#2D4858 RGB(45, 72, 88) RGBA(45, 72, 88, 1) scrollbarSlider.activeBackground
#E74C3C RGB(231, 76, 60) RGBA(231, 76, 60, 1) scrollbarSlider.background
#4D1E0F RGB(77, 30, 15) RGBA(77, 30, 15, 1) scrollbarSlider.hoverBackground
#E74C3C RGB(231, 76, 60) RGBA(231, 76, 60, 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
#65737E RGB(101, 115, 126) RGBA(101, 115, 126, 1) comment.block
#65737E RGB(101, 115, 126) RGBA(101, 115, 126, 1) comment.block.documentation
#65737E RGB(101, 115, 126) RGBA(101, 115, 126, 1) comment.line
#65737E RGB(101, 115, 126) RGBA(101, 115, 126, 1) constant
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.character
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.character.escape
#57B6C2 RGB(87, 182, 194) RGBA(87, 182, 194, 1) constant.numeric
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.numeric.integer
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.numeric.float
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.numeric.hex
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.numeric.octal
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.other
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.other.placeholder
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.regexp
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.rgb-value
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) entity
#C679DD RGB(198, 121, 221) RGBA(198, 121, 221, 1) entity.name
#C679DD RGB(198, 121, 221) RGBA(198, 121, 221, 1) entity.name.class
#82AAFF RGB(130, 170, 255) RGBA(130, 170, 255, 1) entity.name.function
#82AAFF RGB(130, 170, 255) RGBA(130, 170, 255, 1) entity.name.section
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.name.tag
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) entity.name.type
#89DDFF RGB(137, 221, 255) RGBA(137, 221, 255, 1) entity.name.type.enum
#89DDFF RGB(137, 221, 255) RGBA(137, 221, 255, 1) entity.name.type.interface
#89DDFF RGB(137, 221, 255) RGBA(137, 221, 255, 1) entity.name.type.struct
#89DDFF RGB(137, 221, 255) RGBA(137, 221, 255, 1) entity.other
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.other.attribute-name
#BB80B3 RGB(187, 128, 179) RGBA(187, 128, 179, 1) entity.other.inherited-class
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) invalid
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) invalid.deprecated
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) invalid.illegal
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) keyword
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) keyword.control
#C7F7766992EA — — keyword.control.flow
#C7F7766992EA — — keyword.operator
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) keyword.operator.new
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) keyword.operator.assignment
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) keyword.operator.arithmetic
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) keyword.operator.logical
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) keyword.other
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) markup
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) markup.bold
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) markup.changed
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) markup.deleted
#FF5370 RGB(255, 83, 112) RGBA(255, 83, 112, 1) markup.heading
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) markup.inserted
#F1E655 RGB(241, 230, 85) RGBA(241, 230, 85, 1) markup.italic
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) markup.list
#FF5370 RGB(255, 83, 112) RGBA(255, 83, 112, 1) markup.list.numbered
#FF5370 RGB(255, 83, 112) RGBA(255, 83, 112, 1) markup.list.unnumbered
#FF5370 RGB(255, 83, 112) RGBA(255, 83, 112, 1) markup.quote
#F77669 RGB(247, 118, 105) RGBA(247, 118, 105, 1) markup.raw
#F1E655 RGB(241, 230, 85) RGBA(241, 230, 85, 1) meta
#99C794 RGB(153, 199, 148) RGBA(153, 199, 148, 1) meta.function
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) meta.selector
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) meta.tag
#99C794 RGB(153, 199, 148) RGBA(153, 199, 148, 1) punctuation.definition.comment
#65737E RGB(101, 115, 126) RGBA(101, 115, 126, 1) punctuation.definition.string.end
#99C794 RGB(153, 199, 148) RGBA(153, 199, 148, 1) storage
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) storage.modifier
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) storage.type
#C792EA RGB(199, 146, 234) RGBA(199, 146, 234, 1) string
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.interpolated
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.other
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted.double
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted.other
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted.single
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted.triple
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.regexp
#57B6C2 RGB(87, 182, 194) RGBA(87, 182, 194, 1) string.template
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.unquoted
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) support
#56B6C2 RGB(86, 182, 194) RGBA(86, 182, 194, 1) support.class
#FFCB6B RGB(255, 203, 107) RGBA(255, 203, 107, 1) support.constant
#C679DD RGB(198, 121, 221) RGBA(198, 121, 221, 1) support.function
#82AAFF RGB(130, 170, 255) RGBA(130, 170, 255, 1) support.type
#EEFFFF RGB(238, 255, 255) RGBA(238, 255, 255, 1) support.type.property-name
#EEFFFF RGB(238, 255, 255) RGBA(238, 255, 255, 1) variable
#5FB3B3 RGB(95, 179, 179) RGBA(95, 179, 179, 1) variable.function
#5FB3B3 RGB(95, 179, 179) RGBA(95, 179, 179, 1) variable.language
#5FB3B3 RGB(95, 179, 179) RGBA(95, 179, 179, 1) variable.name
#5FB3B3 RGB(95, 179, 179) RGBA(95, 179, 179, 1) variable.other
#5FB3B3 RGB(95, 179, 179) RGBA(95, 179, 179, 1) variable.other.constant
#5FB3B3 RGB(95, 179, 179) RGBA(95, 179, 179, 1) variable.other.property
#5FB3B3 RGB(95, 179, 179) RGBA(95, 179, 179, 1) variable.other.readwrite
#5FB3B3 RGB(95, 179, 179) RGBA(95, 179, 179, 1) variable.parameter
#5FB3B3 RGB(95, 179, 179) RGBA(95, 179, 179, 1)