defaultconstant
The flag of Saga (佐賀県), JP-41, as an SVG string: viewBox 630 by 420 (3:2), 617 B. From Wikimedia Commons, "Flag of Saga Prefecture.svg" (public domain); the /manifest entry gives its author, licence and why it was chosen. It has a viewBox and no width or height, so it fills the box it is put in at its own aspect ratio.
Import it
import value from "@johnmorrisdotca/hata/flags/jp-41";
Definition
const svg: string = "<svg data-hata=\"jp-41\" xmlns=\"http://www.w3.org/2000/svg\" fill=\"#df4133\" viewBox=\"-315 -210 630 420\"><path fill=\"#006462\" d=\"M-315-210h630v420h-630z\"/><g id=\"hata-jp-41-b\"><g id=\"hata-jp-41-a\"><path fill=\"#fff\" d=\"M41.2-71.3a47.5 47.5 0 0 1 65-17.4L129.8-75v27.5A47.5 47.5 0 0 1 82.4 0L-10 5z\"/><path d=\"M50.9-72.7a89 89 0 0 1 11.8 10L32.5-32.5a12.3 12.3 0 0 0 11.9 20.6l41.3-11a89 89 0 0 1 2.7 15.2l-45.5 4a20 20 0 0 1-18.2-31.6z\"/></g><use href=\"#hata-jp-41-a\" transform=\"scale(-1 1)\"/><use href=\"#hata-jp-41-a\" transform=\"rotate(-60)\"/></g><use href=\"#hata-jp-41-b\" transform=\"scale(1-1)\"/><circle r=\"12.3\"/></svg>"
Examples
Example 1
import flag from "@johnmorrisdotca/hata/flags/jp-41";
const host=document.createElement("div");
host.innerHTML = flag; // or toDataUri(flag) from "@johnmorrisdotca/hata" for an <img src>
console.log(host.querySelector("svg")?.getAttribute("viewBox"));Example 2
import { svg } from "@johnmorrisdotca/hata/flags/jp-41";
console.log(svg.startsWith("<svg"),svg.length);true 617What it prints (run when this page was built)