import React from 'react'; import ReactDOMServer from 'react-dom/server'; export function __react_static(ReactComponent: any) { return (attrs: Record, ...children: any): string => { let html = ReactDOMServer.renderToString(React.createElement(ReactComponent, attrs, children)); return html; }; } export function __react_dynamic(ReactComponent: any, importUrl: string, reactUrl: string, reactDomUrl: string) { const placeholderId = `placeholder_${String(Math.random())}`; return (attrs: Record, ...children: any) => { return `
`; }; }