bfanger / svelte-preprocess-react

Seamlessly use React components inside a Svelte app
MIT License
126 stars 6 forks source link

Add support for JSX inside Svelte files? #16

Open bfanger opened 1 year ago

bfanger commented 1 year ago

Look into adding support for JSX syntax into *.svelte files.

<script>
import { CompoundButton, CompoundIcon } from "office-ui-fabric-react";
</script>

<react:CompoundButton icon={<CompoundIcon />} secondaryContent="Secondary content">
  Example
</react:CompoundButton>

The icon={<CompoundIcon />} Should be preprocessed into: icon={createElement(CompoundIcon)}