Skip to content

Commit

Permalink
Merge pull request #646 from raheeliftikhar5/custom-comp-fix
Browse files Browse the repository at this point in the history
Fix custom component
  • Loading branch information
FalkWolsky authored Jan 17, 2024
2 parents b5a7c9a + 788b3ad commit 9d0cab1
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import { EventData, EventTypeEnum } from "./types";
import { hiddenPropertyView } from "comps/utils/propertyUtils";
import { trans } from "i18n";
import { EditorContext } from "comps/editorState";
import * as ReactDOMClient from 'react-dom/client';

// TODO: eventually to embedd in container so we have styling?
// TODO: support different starter templates for different frameworks (react, ANT, Flutter, Angular, etc)
Expand Down Expand Up @@ -60,8 +59,7 @@ const defaultCode = `
);
const ConnectedComponent = ${trans("customComp.sdkGlobalVarName")}.connect(MyCustomComponent);
const container = document.getElementById('root');
const root = ReactDOMClient.createRoot(container);
const root = ReactDOM.createRoot(document.getElementById("root"));
root.render(<ConnectedComponent />);
</script>
Expand Down

0 comments on commit 9d0cab1

Please sign in to comment.