SvgXmlLiketype
What createFlag needs of react-native-svg's SvgXml: a component that takes the SVG as xml, a size and an accessibility label.
Import it
import type { SvgXmlLike } from "@johnmorrisdotca/hata/react-native";
Definition
type SvgXmlLike = ComponentType<{
xml: string;
width: number;
height: number;
accessibilityRole: "image";
accessibilityLabel: string;
}>;
Examples
import { createElement } from "react";
import { createFlag, type SvgXmlLike } from "@johnmorrisdotca/hata/react-native";
const stand: SvgXmlLike = (props) => createElement("svg", { "aria-label": props.accessibilityLabel });
console.log(typeof createFlag(stand)); // "function"functionWhat it prints (run when this page was built)