Skip to content

Instantly share code, notes, and snippets.

@alexbenic
Last active June 23, 2018 09:56
Show Gist options
  • Save alexbenic/557e5269d5095dd0c3b91bc3f886c77d to your computer and use it in GitHub Desktop.
Save alexbenic/557e5269d5095dd0c3b91bc3f886c77d to your computer and use it in GitHub Desktop.
React no jsx.
render() {
return React.createElement(
"div",
{
className:
"helvetica vh-100 vw-100 flex flex-column items-center justify-center f2"
},
[
React.createElement("input", {
className: "ma2 pa1",
placeholder: "Name",
onChange: this.handleChange("firstName")
}),
React.createElement("input", {
className: "ma2 pa1",
placeholder: "Surname",
onChange: this.handleChange("lastName")
}),
React.createElement("div", {className: 'ma2'}, `Hello ${this.state.firstName} ${this.state.lastName}`)
]
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment