Skip to content

Instantly share code, notes, and snippets.

@diego3g
Last active September 11, 2017 18:25
Show Gist options
  • Save diego3g/5155487cc0a349bbbaceca0f7dabe9de to your computer and use it in GitHub Desktop.
Save diego3g/5155487cc0a349bbbaceca0f7dabe9de to your computer and use it in GitHub Desktop.
// src/pages/login.js
import React from "react";
import { View } from "react-native";
import { Card, Button, FormLabel, FormInput } from "react-native-elements";
import { onSignIn } from "../services/auth";
export default ({ navigation }) => (
<View style={{ paddingVertical: 20 }}>
<Card>
<FormLabel>E-mail</FormLabel>
<FormInput placeholder="Digite seu e-mail" />
<FormLabel>Senha</FormLabel>
<FormInput secureTextEntry placeholder="Digite sua senha" />
<Button
buttonStyle={{ marginTop: 20 }}
backgroundColor="#03A9F4"
title="Entrar"
onPress={() => {
onSignIn().then(() => navigation.navigate("SignedIn"));
}}
/>
</Card>
</View>
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment