The svg2jsx transformer


stars 🌟issues ⚠️updated 🛠created 🐣size 🏋️‍♀️
Minified + gzip package size for @balajmarius/svg2jsx in KB


svg2jsx 🌜

Transform SVG into valid JSX

transform(svg, config)


  • svg String The SVG string to be transformed
  • config Map
    • type functional | class The type of the resulting component
    • jsxSingleQuote Boolean Either double or single quotes in JSX attributes


Promise<String> JSX string

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.