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
COVID-19 Theme
colors Workbench UI color keys from the theme JSON colors map.
key HEX RGB RGBA activityBar.background
#450100 RGB(69, 1, 0) RGBA(69, 1, 0, 1) activityBar.foreground
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) activityBarBadge.background
#B80009 RGB(184, 0, 9) RGBA(184, 0, 9, 1) activityBarBadge.foreground
#F5E8E2 RGB(245, 232, 226) RGBA(245, 232, 226, 1) badge.background
#B80009 RGB(184, 0, 9) RGBA(184, 0, 9, 1) badge.foreground
#F5E8E2 RGB(245, 232, 226) RGBA(245, 232, 226, 1) breadcrumb.background
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 1) dropdown.background
#450100 RGB(69, 1, 0) RGBA(69, 1, 0, 1) editor.background
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 1) editor.foreground
#F5E8E2 RGB(245, 232, 226) RGBA(245, 232, 226, 1) editor.lineHighlightBackground
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 1) editor.selectionBackground
#B80009 RGB(184, 0, 9) RGBA(184, 0, 9, 1) editor.selectionHighlightBackground
#A80009 RGB(168, 0, 9) RGBA(168, 0, 9, 1) editorGroupHeader.tabsBackground
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 1) editorSuggestWidget.background
#450100 RGB(69, 1, 0) RGBA(69, 1, 0, 1) editorSuggestWidget.highlightForeground
#B80009 RGB(184, 0, 9) RGBA(184, 0, 9, 1) editorSuggestWidget.selectedBackground
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 1) input.background
#450100 RGB(69, 1, 0) RGBA(69, 1, 0, 1) list.hoverBackground
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 1) notifications.background
#450100 RGB(69, 1, 0) RGBA(69, 1, 0, 1) panel.background
#450100 RGB(69, 1, 0) RGBA(69, 1, 0, 1) sideBar.background
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 1) statusBar.background
#450100 RGB(69, 1, 0) RGBA(69, 1, 0, 1) statusBar.noFolderBackground
#400100 RGB(64, 1, 0) RGBA(64, 1, 0, 1) tab.activeBackground
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 1) tab.inactiveBackground
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 1) terminal.background
#450100 RGB(69, 1, 0) RGBA(69, 1, 0, 1) textLink.foreground
#FF99D6 RGB(255, 153, 214) RGBA(255, 153, 214, 1) welcomePage.background
#470100 RGB(71, 1, 0) RGBA(71, 1, 0, 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
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) comment.block
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) comment.block.documentation
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) comment.line
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) constant
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) constant.character
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) constant.character.escape
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) constant.numeric
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) constant.numeric.integer
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) constant.numeric.float
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) constant.numeric.hex
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) constant.numeric.octal
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) constant.other
#CC7734 RGB(204, 119, 52) RGBA(204, 119, 52, 1) constant.other.placeholder
#CC7734 RGB(204, 119, 52) RGBA(204, 119, 52, 1) constant.regexp
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) constant.rgb-value
#8CABBD RGB(140, 171, 189) RGBA(140, 171, 189, 1) entity
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) entity.name
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) entity.name.class
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) entity.name.function
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) entity.name.method
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) entity.name.namespace
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) entity.name.section
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) entity.name.selector
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) entity.name.tag
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) entity.name.type
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) entity.name.type.enum
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) entity.name.type.interface
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) entity.name.type.struct
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) entity.other
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) entity.other.attribute-name
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) entity.other.inherited-class
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) invalid
#FF1946 RGB(255, 25, 70) RGBA(255, 25, 70, 1) invalid.illegal
#FF1946 RGB(255, 25, 70) RGBA(255, 25, 70, 1) keyword
#73E3FA RGB(115, 227, 250) RGBA(115, 227, 250, 1) keyword.control
#73E3FA RGB(115, 227, 250) RGBA(115, 227, 250, 1) keyword.control.flow
#73E3FA RGB(115, 227, 250) RGBA(115, 227, 250, 1) keyword.operator
#F79463 RGB(247, 148, 99) RGBA(247, 148, 99, 1) keyword.operator.new
#F79463 RGB(247, 148, 99) RGBA(247, 148, 99, 1) keyword.operator.assignment
#F79463 RGB(247, 148, 99) RGBA(247, 148, 99, 1) keyword.operator.arithmetic
#F79463 RGB(247, 148, 99) RGBA(247, 148, 99, 1) keyword.operator.logical
#F79463 RGB(247, 148, 99) RGBA(247, 148, 99, 1) keyword.other
#73E3FA RGB(115, 227, 250) RGBA(115, 227, 250, 1) markup
#AB6526 RGB(171, 101, 38) RGBA(171, 101, 38, 1) markup.bold
#448C27 RGB(68, 140, 39) RGBA(68, 140, 39, 1) markup.changed
#F5E8E2 RGB(245, 232, 226) RGBA(245, 232, 226, 1) markup.deleted
#F5E8E2 RGB(245, 232, 226) RGBA(245, 232, 226, 1) markup.heading
#AA3731 RGB(170, 55, 49) RGBA(170, 55, 49, 1) markup.inline.raw
#AB6526 RGB(171, 101, 38) RGBA(171, 101, 38, 1) markup.inserted
#F5E8E2 RGB(245, 232, 226) RGBA(245, 232, 226, 1) markup.italic
#448C27 RGB(68, 140, 39) RGBA(68, 140, 39, 1) markup.list
#4B83CD RGB(75, 131, 205) RGBA(75, 131, 205, 1) markup.list.numbered
#4B83CD RGB(75, 131, 205) RGBA(75, 131, 205, 1) markup.list.unnumbered
#4B83CD RGB(75, 131, 205) RGBA(75, 131, 205, 1) markup.quote
#7A3E9D RGB(122, 62, 157) RGBA(122, 62, 157, 1) markup.raw
#777777 RGB(119, 119, 119) RGBA(119, 119, 119, 1) meta
#434343 RGB(67, 67, 67) RGBA(67, 67, 67, 1) meta.selector
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) meta.tag
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) punctuation.definition.bracket
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) punctuation.definition.comment
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) punctuation.definition.string.begin
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) punctuation.definition.string.end
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) punctuation.separator
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) punctuation.separator.continuation
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) punctuation.terminator
#90B09F RGB(144, 176, 159) RGBA(144, 176, 159, 1) storage
#73E3FA RGB(115, 227, 250) RGBA(115, 227, 250, 1) storage.modifier
#73E3FA RGB(115, 227, 250) RGBA(115, 227, 250, 1) storage.type
#A1D2FF RGB(161, 210, 255) RGBA(161, 210, 255, 1) string
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) string.interpolated
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) string.other
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) string.quoted
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) string.quoted.double
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) string.quoted.other
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) string.quoted.single
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) string.quoted.triple
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) string.regexp
#B29ED9 RGB(178, 158, 217) RGBA(178, 158, 217, 1) string.template
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) string.unquoted
#856565 RGB(133, 101, 101) RGBA(133, 101, 101, 1) support
#CC7734 RGB(204, 119, 52) RGBA(204, 119, 52, 1) support.class
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) support.constant
#E396D4 RGB(227, 150, 212) RGBA(227, 150, 212, 1) support.function
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) support.type
#A1D2FF RGB(161, 210, 255) RGBA(161, 210, 255, 1) support.type.primitive
#A1D2FF RGB(161, 210, 255) RGBA(161, 210, 255, 1) support.type.property-name
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) support.variable
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) variable
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) variable.function
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) variable.language
#E396D4 RGB(227, 150, 212) RGBA(227, 150, 212, 1) variable.name
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) variable.other
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) variable.other.constant
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) variable.other.property
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) variable.other.readwrite
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1) variable.parameter
#99F0C0 RGB(153, 240, 192) RGBA(153, 240, 192, 1)