Skip to the content

Hata旗

Load a native country or region flag, choose supported framing and keep each drawing’s source, author and licence.

Hata (旗) is Japanese for a flag. About the name

Contents

Reference · Flags a page registers itself

listCustomFlagsfunction

The flags registered and on, in the order they were added, each as { id, name, group, aspect, source }; only one group's with group.

Import it

import { listCustomFlags } from "@johnmorrisdotca/hata/custom";

Definition

function listCustomFlags(options?: { group?: string; }): CustomFlagInfo[]

Parameters

NameTypeDescription
options (optional){ group?: string; }

group, to list one group's flags ("custom" is the default group).

Returns

CustomFlagInfo[]

The list: empty when nothing is registered.

Examples

import { listCustomFlags } from "@johnmorrisdotca/hata/custom";

console.log(listCustomFlags({ group: "Clubs" }).map((flag) => flag.id));
[]

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/hata 1.31.0.