Skip to content

Instantly share code, notes, and snippets.

@bakasura980
Last active April 29, 2020 12:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bakasura980/419deae23105456609034e6ae97c3b4e to your computer and use it in GitHub Desktop.
Save bakasura980/419deae23105456609034e6ae97c3b4e to your computer and use it in GitHub Desktop.
EOSLime shape todo-form render
// ./renders/todo-form.js
const TodoFormHtml = function (context) {
return (
<div>
<form>
<!--
"context" here is TodoApplication class from index.js file
By clicking Add button it will go in TodoApplication.addTodo function
-->
<button type="button" onClick={context.addTodo}>Add</button>
</form>
<!-- New Todo description -->
<input type="text" onChange={context.onNewTodoDescription} placeholder="Description" />
</div>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment