@volue/design-typography
TypeScript icon, indicating that this package has built-in type declarations

0.3.1 • Public • Published

@volue/design-typography

Typography primitives/tokens to be used across Volue's products

Installation

npm install @volue/design-typography --save
# or
yarn add @volue/design-typography

Usage

JavaScript

In JavaScript, design token names are formatted in lower camelCase. Tokens are exported as nested object structure.

const tokens = require('@volue/design-typography');
console.log(tokens.font.family.display);

In JSON, design token names are formatted in SNAKE_CASE.

const tokens = require('@volue/design-typography/dist/index.json');
console.log(tokens['FONT_FAMILY_DISPLAY']);

Sass

Sass variables and map keys are formatted in kebab-case.

// Using variables
@import '~@volue/design-typography/dist/index';

h1 {
  font-family: $font-family-display;
  font-size: $size-font-alpha;
}

Readme

Keywords

none

Package Sidebar

Install

npm i @volue/design-typography

Weekly Downloads

622

Version

0.3.1

License

UNLICENSED

Unpacked Size

39.2 kB

Total Files

16

Last publish

Collaborators

  • aleksanderxxx
  • fima1