Skip to content

Instantly share code, notes, and snippets.

@samuelayo
Created November 30, 2017 11:16
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 samuelayo/6f54ffefd66cd85a989f8565d3480798 to your computer and use it in GitHub Desktop.
Save samuelayo/6f54ffefd66cd85a989f8565d3480798 to your computer and use it in GitHub Desktop.
import * as React from "react";
import UserInterface from './UserInterface'
export default class UserComponent extends React.Component<UserInterface, {}> {
constructor (props: UserInterface){
super(props);
}
render() {
return ( <div>
<h1>User Component</h1>
Hello, {this.props.name}
<br/>
You are {this.props.age} years old,
<br/>
You live at: {this.props.address}
<br/>
you were born: {this.props.dob.toDateString()}
</div>
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment