Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ That's it.

Now, this isn't as simple as I'd like, but federated authentication and wiring up a realtime db isn't either. Additionally, Firebase's authentication system requires a static page and doesn't play nicely with single page apps. So, we redirect back and forth to `auth.html` during login.

## CRUD

This fork includes a CRUD branch which adds a simple example of database CRUD methods.


##Set up

Clone the repo locally and run npm install.
Expand Down
7 changes: 6 additions & 1 deletion public/auth.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<head>
<meta charset="UTF-8">
<title>Sample FirebaseUI App</title>
<link rel="stylesheet" type="text/css" href="style.css">
<script src="https://www.gstatic.com/firebasejs/3.1.0/firebase.js"></script>
<!--
// Initialize Firebase
Expand Down Expand Up @@ -42,7 +43,11 @@
<body>
<!-- The surrounding HTML is left untouched by FirebaseUI.
Your app may use that space for branding, controls and other customizations.-->
<h1>Welcome to My Awesome App</h1>
<h1>FirebaseUI Login</h1>
<div id="firebaseui-auth-container"></div>
<a href="/">
Back to home.
</a>

</body>
</html>
2 changes: 2 additions & 0 deletions public/tos.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@
<html>
<head>
<title>Terms of Service</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<h1>Terms of Service</h1>
<a href="auth.html">
Back to login.
</a>
Expand Down
2 changes: 1 addition & 1 deletion src/containers/ExampleComponent.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class HelloWorld extends Component {
<p>Here is some data in a subcomponent:</p>
<p>
{
JSON.stringify(this.state.data, '/n')
JSON.stringify(this.state, '/n')
}
</p>
</div>
Expand Down
5 changes: 3 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@ const LoggedOut = () => {
<a href="auth.html">
Go to the auth page.
</a>
<span onClick={signOut}>

<div onClick={signOut}>
Sign out
</span>
</div>


</div>
Expand Down
2 changes: 1 addition & 1 deletion src/style.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
body {
background-color: blue;
background-color: darkgray;
color: white;
}