You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
VanJS is a very good framework. It would be great to have an integration package for it here. The SVG dom should be converted to VanJS code by https://github.com/vanjs-org/converter.
However, maybe that'd be overkill. Workaround:
// utils.tsexportconststringToSVGElement=(s: string)=>{constparser=newDOMParser();returnparser.parseFromString(s,'image/svg+xml').documentElement;}// in other fileimport{stringToSVGElement}from'./utils.ts';importIconInfoCirclefrom'@tabler/icons/icons/outline/info-circle.svg?raw';importvanfrom"vanjs-core";const{ div }=van.tags;// whateverdiv(stringToSVGElement(IconInfoCircle))
The text was updated successfully, but these errors were encountered:
VanJS is a very good framework. It would be great to have an integration package for it here. The SVG dom should be converted to VanJS code by https://github.com/vanjs-org/converter.
However, maybe that'd be overkill. Workaround:
The text was updated successfully, but these errors were encountered: