Add support for preact

This commit is contained in:
Eric Fennis
2025-03-19 11:14:07 +01:00
parent 4edcf24fc9
commit cf48dbb2d3
8 changed files with 53 additions and 13 deletions

View File

@@ -13,7 +13,6 @@ export default async ({
const svgContents = await getSvg();
const svgBase64 = base64SVG(svgContents);
return `
import createLucideIcon from '../createLucideIcon';
import { IconNode } from '../types';
@@ -31,7 +30,9 @@ export const __iconNode: IconNode = ${JSON.stringify(children)}
* @returns {JSX.Element} JSX Element
* ${deprecated ? `@deprecated ${deprecationReason}` : ''}
*/
const ${componentName} = createLucideIcon('${componentName}', __iconNode${iconNameAliases != null ? `, ${JSON.stringify(iconNameAliases)}` : ''});
const ${componentName} = createLucideIcon('${componentName}', __iconNode${
iconNameAliases != null ? `, ${JSON.stringify(iconNameAliases)}` : ''
});
export default ${componentName};
`;