MultiTheme
Publisher: Arturo ArevaloThemes in package: 336
A collection of themes ported from TextMate
A collection of themes ported from TextMate
Full workbench mockup using this variant's colors and tokenColors.
Loading...
TextMate scopes and font styles (syntax highlighting rules).
| scope | foreground | fontStyle |
|---|---|---|
| — | #CCCCCC | — |
| comment | #707070 | — |
| keyword.operator | #7A9EC2 | — |
| string | #7A9EC2 | — |
| constant.numeric | #7A9EC2 | — |
| constant.language | #82A56F | — |
| constant.character, constant.other | #7A9EC2 | — |
| variable | #DA8567 | — |
| keyword | #B387A7 | — |
| storage | #B387A7 | — |
| storage.type | #C1944D | — |
| entity.name.class | #DA8567 | — |
| entity.other.inherited-class | #DA8567 | — |
| entity.name.function | #DA8567 | — |
| variable.parameter | #C1944D | — |
| support.function | #7A9EC2 | — |
| support.constant | #7A9EC2 | — |
| support.type, support.class | #82A56F | — |
| support.other.variable | #DA8567 | — |
| invalid | #F9F9F3 | — |
| invalid.deprecated | #F9F9F3 | — |
| markup.heading | #CB4718 | — |
| punctuation.definition.tag.html, punctuation.definition.tag.begin, punctuation.definition.tag.end, entity.name.tag | #7A9EC2 | — |
| entity.other.attribute-name | #B387A7 | — |
| string.quoted.single.html, string.quoted.double.html, string.html | #82A56F | — |
| meta.selector.css, entity.other.attribute-name.id | #B387A7 | — |
| storage.modifier.ts | #C1944D | — |
| cast.expr.ts | #7A9EC2 | — |
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}!`;
}