From 8aa243f1e957bf770423e5bb00ee8ca051e8cd69 Mon Sep 17 00:00:00 2001 From: Mediha Zukic Date: Tue, 20 Jun 2017 14:08:47 +0200 Subject: [PATCH] Update readme --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 42e8948..e90f7e4 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,7 @@ The project shows how to integrate React components into GWT application. GWT ba ## Adding React component +```Java EmbeddedReact.ReactComponentProps componentProps = new EmbeddedReact.ReactComponentProps(); componentProps.onGoToGWTAppClicked = new MouseEventHandler() { @Override @@ -19,6 +20,7 @@ componentProps.onGoToGWTAppClicked = new MouseEventHandler() { }; componentProps.currentLoggedUser = result.getUserName(); ReactDOM.render(React.createElement(EmbeddedReact::loggedInComponent, componentProps), Document.get().getElementById("reactAppDiv")); +``` ## Build and run solution