Skip to content

Commit

Permalink
Updated example
Browse files Browse the repository at this point in the history
  • Loading branch information
n4kz committed May 18, 2017
1 parent e377256 commit 0a3959d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions example/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,11 @@ export default function init() {

render() {
let { errors = {}, secureTextEntry, ...data } = this.state;
let { firstname = 'name', lastname = 'house' } = data;

let defaultEmail = `${firstname}@${lastname}.com`
.replace(/\s+/g, '_')
.toLowerCase();

return (
<ScrollView style={styles.scroll}>
Expand Down Expand Up @@ -185,6 +190,7 @@ export default function init() {
<TextField
ref={this.emailRef}
value={data.email}
defaultValue={defaultEmail}
keyboardType='email-address'
autoCapitalize='none'
autoCorrect={false}
Expand Down

0 comments on commit 0a3959d

Please sign in to comment.