Skip to content

Instantly share code, notes, and snippets.

@hpjaj
Created November 14, 2018 17:59
Show Gist options
  • Save hpjaj/653d923ee9f4ebdc76ff8076c6f00fff to your computer and use it in GitHub Desktop.
Save hpjaj/653d923ee9f4ebdc76ff8076c6f00fff to your computer and use it in GitHub Desktop.
// app/javascript/components/NewPost.js
...
handleSubmit = event => {
event.preventDefault();
}
render() {
return (
<div>
<h1>New Post</h1>
<form onSubmit={e => this.handleSubmit(e)}>
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment