toHex関数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
Writes a colour as #rrggbb.
インポート
import { toHex } from "@johnmorrisdotca/taisen-brackets/backgrounds";
定義
function toHex(c: Parameters<typeof shared.toHex>[0]): string
引数
| 名前 | 型 | 説明 |
|---|---|---|
c | Rgb | The red, green and blue, 0 to 255. |
戻り値
string
The colour in lower-case hexadecimal.
例
import { toHex } from "@johnmorrisdotca/taisen-brackets/backgrounds";
console.log(toHex([47, 93, 74]));#2f5d4a出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。