Skip to main content
VS Code preview Full workbench mockup using this variant's colors and tokenColors.
colors Workbench UI color keys from the theme JSON colors map.
activityBar.activeBackground #ff000000 activityBar.background #0b1e1a activityBar.border #ff000000 activityBar.foreground #999999 activityBar.inactiveForeground #353535 activityBarBadge.background #66ac92 tokenColors TextMate scopes and font styles (syntax highlighting rules).
scope foreground fontStyle punctuation.definition.delayed.unison,punctuation.definition.list.begin.unison,punctuation.definition.list.end.unison,punctuation.definition.ability.begin.unison,punctuation.definition.ability.end.unison,punctuation.operator.assignment.as.unison,punctuation.separator.pipe.unison,punctuation.separator.delimiter.unison,punctuation.definition.hash.unison #64aa90 — variable.other.generic-type.haskell #015c53 — storage.type.haskell #737a79 — support.variable.magic.python
Shiki preview TypeScript sample highlighted with this variant's colors and tokenColors.
Green Terror — Green Terror
activityBarBadge.foreground #999999
badge.background #66ac92
badge.foreground #999999
breadcrumb.activeSelectionForeground #e0e0e0
breadcrumb.background #04171500
breadcrumb.focusForeground #e0e0e0
breadcrumb.foreground #999999cc
button.background #66ac92
button.foreground #ffffff
button.hoverBackground #041715
button.secondaryBackground #66ac92
button.secondaryForeground #ffffff
button.secondaryHoverBackground #041715
checkbox.background #041715
checkbox.border #00000000
checkbox.foreground #999999
debugExceptionWidget.background #333333
debugExceptionWidget.border #474747
debugToolBar.background #333333
debugToolBar.border #474747
diffEditor.border #444444
diffEditor.insertedTextBackground #9bb95533
diffEditor.removedTextBackground #ff000033
dropdown.background #041715
dropdown.border #00000000
dropdown.foreground #999999
editor.background #0b1e1a
editor.findMatchBackground #66ac9232
editor.findMatchBorder #66ac92a9
editor.findMatchHighlightBackground #66ac92a9
editor.findMatchHighlightBorder #99999900
editor.findRangeHighlightBackground #3a3d4166
editor.findRangeHighlightBorder #99999900
editor.foldBackground #264f784d
editor.foreground #015c53
editor.hoverHighlightBackground #264f7840
editor.inactiveSelectionBackground #66ac920c
editor.lineHighlightBackground #9999990A
editor.lineHighlightBorder #282828
editor.rangeHighlightBackground #9999990b
editor.rangeHighlightBorder #99999900
editor.selectionBackground #66ac920c
editor.selectionHighlightBackground #66ac920c
editor.selectionHighlightBorder #66ac92
editor.wordHighlightBackground #575757b8
editor.wordHighlightStrongBackground #015c53
editorBracketMatch.background #0064001a
editorBracketMatch.border #888888
editorCodeLens.foreground #999999
editorCursor.background #999999
editorCursor.foreground #56927c
editorError.background #B73A3400
editorError.border #99999900
editorError.foreground #f48771
editorGroup.border #444444
editorGroup.emptyBackground #0b1e1a
editorGroupHeader.tabsBackground #0b1e1a00
editorGroupHeader.tabsBorder #04171500
editorGutter.addedBackground #587c0c
editorGutter.background #04171500
editorGutter.commentRangeForeground #c5c5c5
editorGutter.deletedBackground #94151b
editorGutter.foldingControlForeground #c5c5c5
editorGutter.modifiedBackground #0c7d9d
editorHoverWidget.background #252526
editorHoverWidget.border #454545
editorHoverWidget.foreground #999999
editorIndentGuide.activeBackground #707070
editorIndentGuide.background #404040
editorInfo.background #4490BF00
editorInfo.border #4490BF00
editorInfo.foreground #75beff
editorLineNumber.activeForeground #999999
editorLineNumber.foreground #66ac92
editorLink.activeForeground #56ff48
editorMarkerNavigation.background #2d2d30
editorMarkerNavigationError.background #f48771
editorMarkerNavigationInfo.background #75beff
editorMarkerNavigationWarning.background #cca700
editorOverviewRuler.background #25252500
editorOverviewRuler.border #7f7f7f4d
editorRuler.foreground #5a5a5a
editorSuggestWidget.background #252526
editorSuggestWidget.border #454545
editorSuggestWidget.foreground #d4d4d4
editorSuggestWidget.highlightForeground #66ac92
editorSuggestWidget.selectedBackground #041715
editorWarning.background #A9904000
editorWarning.border #99999900
editorWarning.foreground #cca700
editorWhitespace.foreground #e3e4e229
editorWidget.background #0b1e1a
editorWidget.foreground #999999
editorWidget.resizeBorder #5F5F5F
focusBorder #66ac92
foreground #999999
gitDecoration.addedResourceForeground #81b88b
gitDecoration.conflictingResourceForeground #6c6cc4
gitDecoration.deletedResourceForeground #c74e39
gitDecoration.ignoredResourceForeground #8c8c8c
gitDecoration.modifiedResourceForeground #e2c08d
gitDecoration.stageDeletedResourceForeground #c74e39
gitDecoration.stageModifiedResourceForeground #e2c08d
gitDecoration.submoduleResourceForeground #8db9e2
gitDecoration.untrackedResourceForeground #73c991
icon.foreground #999999
input.background #041715
input.border #00000000
input.foreground #999999
input.placeholderForeground #999999
inputOption.activeBackground #66ac92
inputOption.activeBorder #007acc00
inputOption.activeForeground #999999
list.activeSelectionBackground #66ac92
list.activeSelectionForeground #ffffff
list.dropBackground #383b3d00
list.focusBackground #041715
list.focusForeground #999999
list.highlightForeground #66ac92
list.hoverBackground #2a2d2e
list.hoverForeground #999999
list.inactiveSelectionBackground #37373d
list.inactiveSelectionForeground #999999
listFilterWidget.background #0b1e1a
listFilterWidget.noMatchesOutline #be1100
listFilterWidget.outline #00000000
menu.background #252526
menu.border #00000085
menu.foreground #999999
menu.selectionBackground #0b1e1a
menu.selectionBorder #00000000
menu.selectionForeground #999999
menu.separatorBackground #bbbbbb
menubar.selectionBackground #041715
menubar.selectionForeground #999999
merge.commonContentBackground #282828
merge.commonHeaderBackground #383838
merge.currentContentBackground #27403B
merge.currentHeaderBackground #367366
merge.incomingContentBackground #28384B
merge.incomingHeaderBackground #395F8F
minimap.background #0b1e1a
minimap.errorHighlight #f48771
minimap.findMatchHighlight #66ac9232
minimap.selectionHighlight #66ac920c
minimap.warningHighlight #cca700
minimapGutter.addedBackground #587c0c
minimapGutter.deletedBackground #94151b
minimapGutter.modifiedBackground #0c7d9d
notificationCenter.border #474747
notificationCenterHeader.background #303031
notificationCenterHeader.foreground #999999
notifications.background #252526
notifications.border #303031
notifications.foreground #999999
notificationsErrorIcon.foreground #f48771
notificationsInfoIcon.foreground #75beff
notificationsWarningIcon.foreground #cca700
notificationToast.border #474747
panel.background #041715
panel.border #66ac92
panelSection.border #80808059
panelTitle.activeBorder #999999
panelTitle.activeForeground #999999
panelTitle.inactiveForeground #353535
peekView.border #007acc
peekViewEditor.background #001f33
peekViewEditor.matchHighlightBackground #ff8f0099
peekViewEditor.matchHighlightBorder #ee931e
peekViewEditorGutter.background #001f33
peekViewResult.background #252526
peekViewResult.fileForeground #999999
peekViewResult.lineForeground #bbbbbb
peekViewResult.matchHighlightBackground #ea5c004d
peekViewResult.selectionBackground #3399ff33
peekViewResult.selectionForeground #999999
peekViewTitle.background #1e1e1e
peekViewTitleDescription.foreground #999999b3
peekViewTitleLabel.foreground #999999
pickerGroup.border #3f3f46
pickerGroup.foreground #66ac92
progressBar.background #66ac92
scrollbar.shadow #041715
scrollbarSlider.activeBackground #bfbfbf66
scrollbarSlider.background #79797966
scrollbarSlider.hoverBackground #646464b3
selection.background #66ac924c
settings.focusedRowBackground #99999907
settings.headerForeground #999999
sideBar.background #041715
sideBar.dropBackground #383b3d00
sideBar.foreground #999999
sideBarSectionHeader.background #00000000
sideBarSectionHeader.border #99999934
sideBarSectionHeader.foreground #999999
sideBarTitle.foreground #bbbbbb
statusBar.background #041715
statusBar.border #041715
statusBar.debuggingBackground #041715
statusBar.debuggingBorder #041715
statusBar.debuggingForeground #041715
statusBar.foreground #999999
statusBar.noFolderBackground #041715
statusBar.noFolderBorder #041715
statusBar.noFolderForeground #999999
statusBarItem.activeBackground #99999925
statusBarItem.hoverBackground #041715
statusBarItem.remoteBackground #041715
statusBarItem.remoteForeground #999999
tab.activeBackground #1e1e1e00
tab.activeBorder #66ac9200
tab.activeBorderTop #66ac9200
tab.activeForeground #999999
tab.border #04171500
tab.hoverBackground #1e1e1e00
tab.hoverBorder #ff000000
tab.hoverForeground #999999
tab.inactiveBackground #0b1e1a00
tab.inactiveForeground #4a4a4a
terminal.ansiBlack #000000
terminal.ansiBlue #2472c8
terminal.ansiBrightBlack #666666
terminal.ansiBrightBlue #3b8eea
terminal.ansiBrightCyan #29b8db
terminal.ansiBrightGreen #23d18b
terminal.ansiBrightMagenta #d670d6
terminal.ansiBrightRed #f14c4c
terminal.ansiBrightWhite #e5e5e5
terminal.ansiBrightYellow #f5f543
terminal.ansiCyan #11a8cd
terminal.ansiGreen #0dbc79
terminal.ansiMagenta #bc3fbc
terminal.ansiRed #cd3131
terminal.ansiWhite #e5e5e5
terminal.ansiYellow #e5e510
terminal.border #80808059
terminal.foreground #999999
terminal.selectionBackground #66ac9214
terminalCursor.background #66ac92
terminalCursor.foreground #999999
textLink.foreground #66ac92
titleBar.activeBackground #0b1e1a
titleBar.activeForeground #999999
titleBar.border #00000000
titleBar.inactiveBackground #0b1e1a
titleBar.inactiveForeground #999999
tree.indentGuidesStroke #66ac92
walkThrough.embeddedEditorBackground #00000050
widget.shadow #041715 #64aa90
punctuation.separator.period.python,punctuation.separator.element.python,punctuation.parenthesis.begin.python,punctuation.parenthesis.end.python #015c53 —
variable.parameter.function.language.special.self.python #019f8f —
storage.modifier.lifetime.rust #015c53 —
support.function.std.rust #115a4a —
entity.name.lifetime.rust #019f8f —
variable.language.rust #64aa90 —
support.constant.edge #015c53 —
constant.other.character-class.regexp #64aa90 —
keyword.operator.quantifier.regexp #737a79 —
punctuation.definition.string.begin,punctuation.definition.string.end #737a79 —
variable.parameter.function #015c53 —
comment markup.link #66ac9234 —
markup.changed.diff #019f8f —
meta.diff.header.from-file,meta.diff.header.to-file,punctuation.definition.from-file.diff,punctuation.definition.to-file.diff #115a4a —
markup.inserted.diff #737a79 —
markup.deleted.diff #64aa90 —
meta.function.c,meta.function.cpp #64aa90 —
punctuation.section.block.begin.bracket.curly.cpp,punctuation.section.block.end.bracket.curly.cpp,punctuation.terminator.statement.c,punctuation.section.block.begin.bracket.curly.c,punctuation.section.block.end.bracket.curly.c,punctuation.section.parens.begin.bracket.round.c,punctuation.section.parens.end.bracket.round.c,punctuation.section.parameters.begin.bracket.round.c,punctuation.section.parameters.end.bracket.round.c #015c53 —
punctuation.separator.key-value #015c53 —
keyword.operator.expression.import #115a4a —
support.constant.math #019f8f —
support.constant.property.math #737a79 —
variable.other.constant #019f8f —
storage.type.annotation.java, storage.type.object.array.java #019f8f —
punctuation.section.block.begin.java,punctuation.section.block.end.java,punctuation.definition.method-parameters.begin.java,punctuation.definition.method-parameters.end.java,meta.method.identifier.java,punctuation.section.method.begin.java,punctuation.section.method.end.java,punctuation.terminator.java,punctuation.section.class.begin.java,punctuation.section.class.end.java,punctuation.section.inner-class.begin.java,punctuation.section.inner-class.end.java,meta.method-call.java,punctuation.section.class.begin.bracket.curly.java,punctuation.section.class.end.bracket.curly.java,punctuation.section.method.begin.bracket.curly.java,punctuation.section.method.end.bracket.curly.java,punctuation.separator.period.java,punctuation.bracket.angle.java,punctuation.definition.annotation.java,meta.method.body.java #015c53 —
storage.modifier.import.java,storage.type.java,storage.type.generic.java #019f8f —
keyword.operator.instanceof.java #015c53 —
meta.definition.variable.name.java #64aa90 —
keyword.operator.logical #c5d3cf —
keyword.operator.bitwise #c5d3cf —
keyword.operator.channel #c5d3cf —
support.constant.property-value.scss,support.constant.property-value.css #737a79 —
keyword.operator.css,keyword.operator.scss,keyword.operator.less #c5d3cf —
support.constant.color.w3c-standard-color-name.css,support.constant.color.w3c-standard-color-name.scss #737a79 —
punctuation.separator.list.comma.css #015c53 —
support.constant.color.w3c-standard-color-name.css #737a79 —
support.type.vendored.property-name.css #c5d3cf —
support.module.node,support.type.object.module,support.module.node #019f8f —
entity.name.type.module #019f8f —
variable.other.readwrite,meta.object-literal.key,support.variable.property,support.variable.object.process,support.variable.object.node #64aa90 —
support.constant.json #737a79 —
keyword.operator.expression.instanceof, keyword.operator.new, keyword.operator.ternary, keyword.operator.optional, keyword.operator.expression.keyof #015c53 —
support.type.object.console #64aa90 —
support.variable.property.process #737a79 —
entity.name.function,support.function.console #115a4a —
keyword.operator.misc.rust #015c53 —
keyword.operator.sigil.rust #015c53 —
keyword.operator.delete #015c53 —
support.type.object.dom #c5d3cf —
support.variable.dom,support.variable.property.dom #64aa90 —
keyword.operator.arithmetic,keyword.operator.comparison,keyword.operator.decrement,keyword.operator.increment,keyword.operator.relational #c5d3cf —
keyword.operator.assignment.c,keyword.operator.comparison.c,keyword.operator.c,keyword.operator.increment.c,keyword.operator.decrement.c,keyword.operator.bitwise.shift.c,keyword.operator.assignment.cpp,keyword.operator.comparison.cpp,keyword.operator.cpp,keyword.operator.increment.cpp,keyword.operator.decrement.cpp,keyword.operator.bitwise.shift.cpp #015c53 —
punctuation.separator.delimiter #015c53 —
punctuation.separator.c,punctuation.separator.cpp #015c53 —
support.type.posix-reserved.c,support.type.posix-reserved.cpp #c5d3cf —
keyword.operator.sizeof.c,keyword.operator.sizeof.cpp #015c53 —
variable.parameter.function.language.python #737a79 —
support.type.python #c5d3cf —
keyword.operator.logical.python #015c53 —
variable.parameter.function.python #737a79 —
punctuation.definition.arguments.begin.python,punctuation.definition.arguments.end.python,punctuation.separator.arguments.python,punctuation.definition.list.begin.python,punctuation.definition.list.end.python #015c53 —
meta.function-call.generic.python #115a4a —
constant.character.format.placeholder.other.python #737a79 —
keyword.operator.assignment.compound #015c53 —
keyword.operator.assignment.compound.js,keyword.operator.assignment.compound.ts #c5d3cf —
entity.name.namespace #019f8f —
variable.language #019f8f —
token.variable.parameter.java #015c53 —
import.storage.java #019f8f —
token.package.keyword #015c53 —
entity.name.function, meta.require, support.function.any-method, variable.function #115a4a —
entity.name.type.namespace #019f8f —
support.class, entity.name.type.class #019f8f —
entity.name.class.identifier.namespace.type #019f8f —
entity.name.class, variable.other.class.js, variable.other.class.ts #019f8f —
variable.other.class.php #64aa90 —
control.elements, keyword.operator.less #737a79 —
keyword.other.special-method #115a4a —
keyword.operator.expression.delete,keyword.operator.expression.in,keyword.operator.expression.of,keyword.operator.expression.instanceof,keyword.operator.new,keyword.operator.expression.typeof,keyword.operator.expression.void #015c53 —
token.storage.type.java #019f8f —
support.type.property-name #015c53 —
support.constant.property-value #015c53 —
support.constant.font-name #737a79 —
entity.other.inherited-class #019f8f —
constant.other.symbol #c5d3cf —
punctuation.definition.constant #737a79 —
entity.other.attribute-name #737a79 —
entity.other.attribute-name.id #115a4a italic bold
entity.other.attribute-name.class.css #737a79 bold
markup.heading punctuation.definition.heading, entity.name.section #115a4a —
keyword.other.unit #64aa90 —
markup.bold,todo.bold #737a79 —
punctuation.definition.bold #019f8f —
markup.italic, punctuation.definition.italic,todo.emphasis #015c53 —
entity.name.section.markdown #64aa90 —
punctuation.definition.heading.markdown #64aa90 —
punctuation.definition.list.begin.markdown #64aa90 —
markup.heading.setext #015c53 —
punctuation.definition.bold.markdown #737a79 —
markup.inline.raw.markdown #737a79 —
markup.inline.raw.string.markdown #737a79 —
punctuation.definition.list.markdown #64aa90 —
punctuation.definition.string.begin.markdown, punctuation.definition.string.end.markdown, punctuation.definition.metadata.markdown #64aa90 —
beginning.punctuation.definition.list.markdown #64aa90 —
punctuation.definition.metadata.markdown #64aa90 —
markup.underline.link.markdown,markup.underline.link.image.markdown #015c53 —
string.other.link.title.markdown,string.other.link.description.markdown #115a4a —
constant.character.escape #c5d3cf —
punctuation.section.embedded, variable.interpolation #64aa90 —
punctuation.section.embedded.begin,punctuation.section.embedded.end #015c53 —
invalid.illegal.bad-ampersand.html #015c53 —
invalid.deprecated #999999 —
invalid.unimplemented #999999 —
source.json meta.structure.dictionary.json > string.quoted.json #64aa90 —
source.json meta.structure.dictionary.json > string.quoted.json > punctuation.string #64aa90 —
source.json meta.structure.dictionary.json > value.json > string.quoted.json,source.json meta.structure.array.json > value.json > string.quoted.json,source.json meta.structure.dictionary.json > value.json > string.quoted.json > punctuation,source.json meta.structure.array.json > value.json > string.quoted.json > punctuation #737a79 —
source.json meta.structure.dictionary.json > constant.language.json,source.json meta.structure.array.json > constant.language.json #c5d3cf —
support.type.property-name.json #64aa90 —
support.type.property-name.json punctuation #64aa90 —
text.html.laravel-blade source.php.embedded.line.html entity.name.tag.laravel-blade #015c53 —
text.html.laravel-blade source.php.embedded.line.html support.constant.laravel-blade #015c53 —
support.other.namespace.use.php,support.other.namespace.use-as.php,support.other.namespace.php,entity.other.alias.php,meta.interface.php #019f8f —
keyword.operator.error-control.php #015c53 —
keyword.operator.type.php #015c53 —
punctuation.section.array.begin.php #015c53 —
punctuation.section.array.end.php #015c53 —
invalid.illegal.non-null-typehinted.php #f44747 —
storage.type.php,meta.other.type.phpdoc.php,keyword.other.type.php,keyword.other.array.phpdoc.php #019f8f —
meta.function-call.php,meta.function-call.object.php,meta.function-call.static.php #115a4a —
punctuation.definition.parameters.begin.bracket.round.php,punctuation.definition.parameters.end.bracket.round.php,punctuation.separator.delimiter.php,punctuation.section.scope.begin.php,punctuation.section.scope.end.php,punctuation.terminator.expression.php,punctuation.definition.arguments.begin.bracket.round.php,punctuation.definition.arguments.end.bracket.round.php,punctuation.definition.storage-type.begin.bracket.round.php,punctuation.definition.storage-type.end.bracket.round.php,punctuation.definition.array.begin.bracket.round.php,punctuation.definition.array.end.bracket.round.php,punctuation.definition.begin.bracket.round.php,punctuation.definition.end.bracket.round.php,punctuation.definition.begin.bracket.curly.php,punctuation.definition.end.bracket.curly.php,punctuation.definition.section.switch-block.end.bracket.curly.php,punctuation.definition.section.switch-block.start.bracket.curly.php,punctuation.definition.section.switch-block.begin.bracket.curly.php,punctuation.definition.section.switch-block.end.bracket.curly.php #015c53 —
support.constant.core.rust #737a79 —
support.constant.ext.php,support.constant.std.php,support.constant.core.php,support.constant.parser-token.php #737a79 —
entity.name.goto-label.php,support.other.php #115a4a —
keyword.operator.logical.php,keyword.operator.bitwise.php,keyword.operator.arithmetic.php #c5d3cf —
keyword.operator.regexp.php #015c53 —
keyword.operator.comparison.php #c5d3cf —
keyword.operator.heredoc.php,keyword.operator.nowdoc.php #015c53 —
meta.function.decorator.python #115a4a —
support.token.decorator.python,meta.function.decorator.identifier.python #c5d3cf —
function.parameter #015c53 —
function.parameter.ruby, function.parameter.cs #015c53 —
constant.language.symbol.ruby #c5d3cf —
inline-color-decoration rgb-value #737a79 —
support.type.primitive.ts,support.type.builtin.ts,support.type.primitive.tsx,support.type.builtin.tsx #019f8f —
block.scope.end,block.scope.begin #015c53 —
entity.name.variable.local.cs #64aa90 —
token.error-token #f44747 —
token.debug-token #015c53 —
punctuation.definition.template-expression.begin, punctuation.definition.template-expression.end, punctuation.section.embedded #015c53 —
meta.template.expression #015c53 —
keyword.operator.module #015c53 —
support.type.type.flowtype #115a4a —
support.type.primitive #019f8f —
meta.property.object #64aa90 —
variable.parameter.function.js #64aa90 —
keyword.other.template.begin #737a79 —
keyword.other.template.end #737a79 —
keyword.other.substitution.begin #737a79 —
keyword.other.substitution.end #737a79 —
keyword.operator.assignment #c5d3cf —
keyword.operator.assignment.go #019f8f —
keyword.operator.arithmetic.go, keyword.operator.address.go #015c53 —
entity.name.package.go #019f8f —
support.type.prelude.elm #c5d3cf —
support.constant.elm #737a79 —
punctuation.quasi.element #015c53 —
constant.character.entity #64aa90 —
entity.other.attribute-name.pseudo-element, entity.other.attribute-name.pseudo-class #c5d3cf —
entity.global.clojure #019f8f —
meta.symbol.clojure #64aa90 —
constant.keyword.clojure #c5d3cf —
meta.arguments.coffee, variable.parameter.function.coffee #64aa90 —
meta.scope.prerequisites.makefile #64aa90 —
storage.modifier.import.groovy #019f8f —
meta.method.groovy #115a4a —
meta.definition.variable.name.groovy #64aa90 —
meta.definition.class.inherited.classes.groovy #737a79 —
support.variable.semantic.hlsl #019f8f —
support.type.texture.hlsl, support.type.sampler.hlsl, support.type.object.hlsl, support.type.object.rw.hlsl, support.type.fx.hlsl, support.type.object.hlsl #015c53 —
text.variable, text.bracketed #64aa90 —
support.type.swift, support.type.vb.asp #019f8f —
entity.name.function.xi #019f8f —
entity.name.class.xi #c5d3cf —
constant.character.character-class.regexp.xi #64aa90 —
constant.regexp.xi #015c53 —
keyword.control.xi #c5d3cf —
beginning.punctuation.definition.quote.markdown.xi #737a79 —
beginning.punctuation.definition.list.markdown.xi #66ac9234 —
constant.character.xi #115a4a —
constant.other.color.rgb-value.xi #999999 —
punctuation.definition.tag.xi #66ac9234 —
entity.name.label.cs, entity.name.scope-resolution.function.call, entity.name.scope-resolution.function.definition #019f8f —
entity.name.label.cs, markup.heading.setext.1.markdown, markup.heading.setext.2.markdown #64aa90 —
meta.brace.square #015c53 —
comment, punctuation.definition.comment #66ac9234 italic
markup.quote.markdown #66ac9234 —
punctuation.definition.block.sequence.item.yaml #015c53 —
constant.language.symbol.elixir #c5d3cf —
entity.other.attribute-name.js,entity.other.attribute-name.ts,entity.other.attribute-name.jsx,entity.other.attribute-name.tsx,variable.parameter,variable.language.super — italic
comment.line.double-slash,comment.block.documentation — italic
keyword.control.import.python,keyword.control.flow.python — italic
markup.italic.markdown — italic
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 } !` ;
}
fetchUser.ts
index.ts
README.md
src
components
fetchUser.ts
src
components
fetchUser.ts
fetchUser 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
Problems1
Output
Debug Console
Terminal
Ports
~/my-project $ pnpm dev
▲ Next.js ready on http://localhost:3000
✓ compiled client and server successfully in 412ms
wait - compiling /theme/vscode...
~/my-project
main*
Green Terror | Coding Theme
Button.tsx
31
$
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 } !` ;
}