Skip to content

pantoken-root / formats/less/src / toLess

Fušla: toLess() ​

toLess(tokens, options?): string

Eksperimentála

Geavahit Less-muhtunid token IR:iin.

Parametera ​

tokens ​

ruvvojuvvon Token[]

IR (go @pantoken/tokens.)

options? ​

ToLessOptions = {}

ToLessOptions.

Gullii / Gávdnat ​

string

Less čuovgga striŋga.

Exempla ​

Geavahit dávjá (lohká) muhtunid

ts
import { toLess } from "@pantoken/less";
import { tokens } from "@pantoken/tokens";

toLess(tokens); // "@instui-color-brand: #0374b5;\n…"

Ráddet bures pime modu mii ožžon eará theme

ts
import { toLess } from "@pantoken/less";
import { byTheme } from "@pantoken/tokens";

toLess(byTheme("canvas"), { mode: "dark" });