Skip to content

Theemo / @theemo/tokens / Token

Interface: Token<T>

Token, with all properties shared amongst various token types used throughout theemo.

Remarks

Definitions for token:

"The single source of truth to name and store a design decision, distributed so teams can use it across design tools and coding languages." (Design Tokens Community Group)

"Design Tokens are a methodology. IMHO, saying "design tokens are just variables" is like saying "responsive design is just media queries". It's a technology-agnostic architecture and process for scaling design across multiple platforms and devices, including native, and more." (Jina Anne)

"Design Tokens, Decisions Propagated Through a System" (Nathan Curtis)

Type parameters

Type parameterValue
T extends TokenType"unknown"

Properties

description?

ts
optional description: string;

The description for the token

See

Design Tokens Format Module

Source

packages/@theemo/tokens/src/token.ts:31


name

ts
name: string;

The tokens name

See

Source

packages/@theemo/tokens/src/token.ts:24


type?

ts
optional type: keyof TokenTypeRegistry | T;

The type helps token translation tools to generate the respective value in the appropriate format.

Remarks

Resources:

See

Source

packages/@theemo/tokens/src/token.ts:44


value?

ts
optional value: string | ValueFor<T>;

The tokens computed value

Remarks

References:

See

DTCG Glossary (Design Token Value)

Source

packages/@theemo/tokens/src/token.ts:55