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
One Dark Plus
colors Workbench UI color keys from the theme JSON colors map.
key HEX RGB RGBA activeTab.background
#2E2E4C RGB(46, 46, 76) RGBA(46, 46, 76, 1) activityBar.background
#1C1C26 RGB(28, 28, 38) RGBA(28, 28, 38, 1) editor.background
#1D1D2F RGB(29, 29, 47) RGBA(29, 29, 47, 1) editor.foreground
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) editor.lineHighlightBackground
#15152A RGB(21, 21, 42) RGBA(21, 21, 42, 1) editor.selectionBackground
#373760 RGB(55, 55, 96) RGBA(55, 55, 96, 1) editorCursor.foreground
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) editorGroupHeader.tabsBackground
#121223 RGB(18, 18, 35) RGBA(18, 18, 35, 1) editorWhitespace.foreground
#373760 RGB(55, 55, 96) RGBA(55, 55, 96, 1) input.background
#252535 RGB(37, 37, 53) RGBA(37, 37, 53, 1) panel.background
#121223 RGB(18, 18, 35) RGBA(18, 18, 35, 1) peekViewResults.background
#3B4252 RGB(59, 66, 82) RGBA(59, 66, 82, 1) peekViewTitle.background
#3B4252 RGB(59, 66, 82) RGBA(59, 66, 82, 1) sideBar.background
#181826 RGB(24, 24, 38) RGBA(24, 24, 38, 1) statusBar.background
#2E2E4C RGB(46, 46, 76) RGBA(46, 46, 76, 1) statusBar.debuggingBackground
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) statusBar.noFolderBackground
#585889 RGB(88, 88, 137) RGBA(88, 88, 137, 1) tab.border
#1C1C26 RGB(28, 28, 38) RGBA(28, 28, 38, 1) tab.inactiveBackground
#121223 RGB(18, 18, 35) RGBA(18, 18, 35, 1) tabsContainer.background
#181826 RGB(24, 24, 38) RGBA(24, 24, 38, 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
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 1) comment.block
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 1) comment.block.documentation
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 1) comment.line
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 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
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.name.function
#9585FF RGB(149, 133, 255) RGBA(149, 133, 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
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) entity.name.type.enum
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) entity.name.type.interface
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) entity.name.type.struct
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) entity.other
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.other.attribute-name
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) entity.other.inherited-class
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 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
#FF387E RGB(255, 56, 126) RGBA(255, 56, 126, 1) keyword.control
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) keyword.control.flow
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) keyword.operator
#26E687 RGB(38, 230, 135) RGBA(38, 230, 135, 1) keyword.operator.new
#26E687 RGB(38, 230, 135) RGBA(38, 230, 135, 1) keyword.operator.assignment
#26E687 RGB(38, 230, 135) RGBA(38, 230, 135, 1) keyword.operator.arithmetic
#26E687 RGB(38, 230, 135) RGBA(38, 230, 135, 1) keyword.operator.logical
#26E687 RGB(38, 230, 135) RGBA(38, 230, 135, 1) keyword.other
#FF387E RGB(255, 56, 126) RGBA(255, 56, 126, 1) markup
#C679DD RGB(198, 121, 221) RGBA(198, 121, 221, 1) markup.bold
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) markup.changed
#C679DD RGB(198, 121, 221) RGBA(198, 121, 221, 1) markup.deleted
#DF6A73 RGB(223, 106, 115) RGBA(223, 106, 115, 1) markup.heading
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) markup.inserted
#90C378 RGB(144, 195, 120) RGBA(144, 195, 120, 1) markup.italic
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) markup.list
#DF6A73 RGB(223, 106, 115) RGBA(223, 106, 115, 1) markup.quote
#D2945D RGB(210, 148, 93) RGBA(210, 148, 93, 1) markup.raw
#90C378 RGB(144, 195, 120) RGBA(144, 195, 120, 1) meta
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) meta.function
#56B6C2 RGB(86, 182, 194) RGBA(86, 182, 194, 1) meta.selector
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) meta.tag
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) punctuation.definition.comment
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 1) storage
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) storage.modifier
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) storage.type
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) string
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) string.interpolated
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) string.other
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) string.quoted
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) string.quoted.double
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) string.quoted.other
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) string.quoted.single
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) string.quoted.triple
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) string.regexp
#57B6C2 RGB(87, 182, 194) RGBA(87, 182, 194, 1) string.template
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) string.unquoted
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) support
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) support.class
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) support.constant
#C679DD RGB(198, 121, 221) RGBA(198, 121, 221, 1) support.function
#F7547A RGB(247, 84, 122) RGBA(247, 84, 122, 1) support.type
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) support.type.primitive
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) support.type.property-name
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) support.variable
#18BC6C RGB(24, 188, 108) RGBA(24, 188, 108, 1) variable
#FE5C70 RGB(254, 92, 112) RGBA(254, 92, 112, 1) variable.function
#FE5C70 RGB(254, 92, 112) RGBA(254, 92, 112, 1) variable.language
#FE5C70 RGB(254, 92, 112) RGBA(254, 92, 112, 1) variable.name
#FE5C70 RGB(254, 92, 112) RGBA(254, 92, 112, 1) variable.other
#FE5C70 RGB(254, 92, 112) RGBA(254, 92, 112, 1) variable.other.constant
#FE5C70 RGB(254, 92, 112) RGBA(254, 92, 112, 1) variable.other.property
#FE5C70 RGB(254, 92, 112) RGBA(254, 92, 112, 1) variable.other.readwrite
#FE5C70 RGB(254, 92, 112) RGBA(254, 92, 112, 1) variable.parameter
#FE5C70 RGB(254, 92, 112) RGBA(254, 92, 112, 1)