Son Dark Eight
Publisher: soneightThemes in package: 1
cyan color based dark theme
cyan color based dark theme
Full workbench mockup using this variant's colors and tokenColors.
Loading...
Workbench UI color keys from the theme JSON colors map.
TextMate scopes and font styles (syntax highlighting rules).
| scope | foreground | fontStyle |
|---|---|---|
| constant, entity.name.type, keyword.operator, punctuation, string.quoted, storage.modifier, storage.type.built-in, storage.type.integral, storage.type.js, string.source.cmake, support.constant, variable.other | #C0C0C0 | — |
| comment, entity.name.namespace, entity.name.scope-resolution, invalid, punctuation.definition.comment, punctuation.separator.namespace, punctuation.separator.scope-resolution | #808080 | — |
| constant.other.placeholder, entity.other.attribute-name, markup.underline.link, storage.source.cmake, string.other.link, variable, variable.other.declare, variable.other.local, variable.other.readwrite | #80C0C0 | — |
| constant.character.escape, keyword.other, string | #C080C0 | — |
| storage.type.template, support | #8080C0 | — |
| entity, entity.name.function, keyword.other.operator, support.function | #C0C080 | — |
| entity.source.cmake, storage, storage.type, support.type | #80C080 | — |
| entity.name.tag, keyword, punctuation.definition | #C08080 | — |
| comment, constant, entity.name.function.preprocessor, string.quoted, variable.other.enummember | — | italic |
| punctuation, variable.language | — | bold |
| punctuation.separator.pointer-access | — | bold strikethrough |
| string.quoted.double.include, string.quoted.other.lt-gt.include | — | underline 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}!`;
}