Reference
On-demand flag loading
import { … } from "@johnmorrisdotca/hata/load";
3929.4 kB minified and gzipped, with everything it imports (measured with esbuild)
Exports
| Name | Kind | What it is |
|---|---|---|
flag | function | A flag's SVG string by its code, loaded when asked for: one dynamic import of /flags/<code>. |
flagDataUri | function | A flag as a data: URI by its code, loaded when asked for: ready for an <img src> or a CSS url(). |
FlagOptions | type | What flag() takes: everything frame() takes, and variant, which of the place's flags in real use to load. |
FrameOptions | type | How to frame a flag: its shape, how it fits, and a label for assistive technology. |