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
Seti
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
#4A5F68 RGB(74, 95, 104) RGBA(74, 95, 104, 1) comment.block
#4A5F68 RGB(74, 95, 104) RGBA(74, 95, 104, 1) comment.block.documentation
#4A5F68 RGB(74, 95, 104) RGBA(74, 95, 104, 1) comment.line
#4A5F68 RGB(74, 95, 104) RGBA(74, 95, 104, 1) constant
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.character
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.character.escape
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.numeric
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.numeric.integer
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.numeric.float
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.numeric.hex
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.numeric.octal
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.other
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.other.placeholder
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.regexp
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) constant.rgb-value
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) entity
#3CADD7 RGB(60, 173, 215) RGBA(60, 173, 215, 1) entity.name
#3CADD7 RGB(60, 173, 215) RGBA(60, 173, 215, 1) entity.name.class
#FF4377 RGB(255, 67, 119) RGBA(255, 67, 119, 1) entity.name.function
#55B5DB RGB(85, 181, 219) RGBA(85, 181, 219, 1) entity.name.method
#3CADD7 RGB(60, 173, 215) RGBA(60, 173, 215, 1) entity.name.namespace
#3CADD7 RGB(60, 173, 215) RGBA(60, 173, 215, 1) entity.name.section
#3CADD7 RGB(60, 173, 215) RGBA(60, 173, 215, 1) entity.name.selector
#3CADD7 RGB(60, 173, 215) RGBA(60, 173, 215, 1) entity.name.tag
#55B5DB RGB(85, 181, 219) RGBA(85, 181, 219, 1) entity.name.type
#55B5DB RGB(85, 181, 219) RGBA(85, 181, 219, 1) entity.name.type.enum
#55B5DB RGB(85, 181, 219) RGBA(85, 181, 219, 1) entity.name.type.interface
#55B5DB RGB(85, 181, 219) RGBA(85, 181, 219, 1) entity.name.type.struct
#55B5DB RGB(85, 181, 219) RGBA(85, 181, 219, 1) entity.other
#3CADD7 RGB(60, 173, 215) RGBA(60, 173, 215, 1) entity.other.attribute-name
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) entity.other.inherited-class
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) invalid
#F8F8F8 RGB(248, 248, 248) RGBA(248, 248, 248, 1) invalid.deprecated
#E6002B RGB(230, 0, 43) RGBA(230, 0, 43, 1) invalid.illegal
#F8F8F8 RGB(248, 248, 248) RGBA(248, 248, 248, 1) keyword
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) keyword.control
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) keyword.control.flow
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) keyword.operator
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) keyword.operator.new
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) keyword.operator.assignment
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) keyword.operator.arithmetic
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) keyword.operator.logical
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) keyword.other
#FF026A RGB(255, 2, 106) RGBA(255, 2, 106, 1) markup
#565656 RGB(86, 86, 86) RGBA(86, 86, 86, 1) markup.changed
#967EFB RGB(150, 126, 251) RGBA(150, 126, 251, 1) markup.deleted
#F92672 RGB(249, 38, 114) RGBA(249, 38, 114, 1) markup.inserted
#A6E22E RGB(166, 226, 46) RGBA(166, 226, 46, 1) markup.list
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) markup.list.numbered
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) markup.underline
#CD4046 RGB(205, 64, 70) RGBA(205, 64, 70, 1) markup.underline.link
#CD4046 RGB(205, 64, 70) RGBA(205, 64, 70, 1) meta
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) meta.class
#FF4377 RGB(255, 67, 119) RGBA(255, 67, 119, 1) meta.function-call
#CBAF6C RGB(203, 175, 108) RGBA(203, 175, 108, 1) meta.selector
#D4D7D6 RGB(212, 215, 214) RGBA(212, 215, 214, 1) meta.tag
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) punctuation.definition.bracket
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) punctuation.definition.comment
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) punctuation.definition.string.begin
#55B5DB RGB(85, 181, 219) RGBA(85, 181, 219, 1) punctuation.definition.string.end
#55B5DB RGB(85, 181, 219) RGBA(85, 181, 219, 1) punctuation.separator
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) punctuation.separator.continuation
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) punctuation.terminator
#858D8A RGB(133, 141, 138) RGBA(133, 141, 138, 1) storage
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) storage.modifier
#276AFF RGB(39, 106, 255) RGBA(39, 106, 255, 1) storage.type
#E6CD69 RGB(230, 205, 105) RGBA(230, 205, 105, 1) string
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) string.interpolated
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) string.other
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) string.quoted
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) string.quoted.double
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) string.quoted.other
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) string.quoted.single
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) string.quoted.triple
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) string.regexp
#FFB454 RGB(255, 180, 84) RGBA(255, 180, 84, 1) string.template
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) string.unquoted
#3C444D RGB(60, 68, 77) RGBA(60, 68, 77, 1) support
#08D879 RGB(8, 216, 121) RGBA(8, 216, 121, 1) support.class
#A074C4 RGB(160, 116, 196) RGBA(160, 116, 196, 1) support.constant
#CD3F45 RGB(205, 63, 69) RGBA(205, 63, 69, 1) support.function
#A074C4 RGB(160, 116, 196) RGBA(160, 116, 196, 1) support.other
#EF6AA7DD RGB(239, 106, 167) RGBA(239, 106, 167, 0.867) support.type
#A074C4 RGB(160, 116, 196) RGBA(160, 116, 196, 1) support.type.property-name
#A074C4 RGB(160, 116, 196) RGBA(160, 116, 196, 1) variable
#E6CD69 RGB(230, 205, 105) RGBA(230, 205, 105, 1) variable.function
#E6CD69 RGB(230, 205, 105) RGBA(230, 205, 105, 1) variable.language
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) variable.name
#E6CD69 RGB(230, 205, 105) RGBA(230, 205, 105, 1) variable.other
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) variable.other.constant
#FFA325 RGB(255, 163, 37) RGBA(255, 163, 37, 1) variable.other.property
#AA00AA RGB(170, 0, 170) RGBA(170, 0, 170, 1) variable.other.readwrite
#9FCA56 RGB(159, 202, 86) RGBA(159, 202, 86, 1) variable.parameter
#55B5DB RGB(85, 181, 219) RGBA(85, 181, 219, 1)