Skip to content

Commit 6df0136

Browse files
author
jacobawenger
committed
Added READMEs for examples and todoApp directories
1 parent 69e2b65 commit 6df0136

File tree

3 files changed

+51
-1
lines changed

3 files changed

+51
-1
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ The ReactFireMixin can be added to you project in two ways:
1414
* Manually copy ReactFireMixin.js from GitHub to you local directory.
1515
* Use bower: `bower install ReactFire`
1616

17-
To use the ReactFireMixin in a React component, update the component's mixins property:
17+
To use the ReactFireMixin in a React component, add it to the component's mixins property:
1818

1919
var ExampleComponent = React.createClass({
2020
mixins: [ReactFireMixin],

examples/README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
ReactFire Examples
2+
==================
3+
4+
Have you come up with a cool example that uses the ReactFireMixin? Submit a pull request and share
5+
it with everyone else by putting in this /examples/ directory. Please make sure to include a README.md
6+
file in your examples base directory which explains what the example is and how to run it.
7+
8+
Check out the [todoApp example](./todoApp/) to see how to structure your examples.

examples/todoApp/README.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
ReactFire Todo App Example
2+
==========================
3+
4+
Live Demo
5+
---------
6+
You can view a live version of this demo [here](https://reactfiretodoapp.firebaseapp.com/).
7+
8+
Setup Instructions
9+
--------------------
10+
To run this example locally, either download the whole ReactFire repo or just this /todoApp/
11+
directory. From the /todoApp/ directory, install the needed dependencies via bower:
12+
13+
```bash
14+
$ bower install
15+
```
16+
17+
Then start up a server via Python (or your favorite method):
18+
19+
```bash
20+
$ python -m SimpleHTTPServer 8080
21+
```
22+
23+
Now you should be able to visit the example in the browser of your choice at [http://127.0.0.1:8080/](http://127.0.0.1:8080/).
24+
25+
Description
26+
-----------
27+
This example shows three different ways to make a Todo app using React. It is adapted from the
28+
Todo app example on the [ReactJS homepage](http://facebook.github.io/react/). There are three
29+
different versions of the Todo app example:
30+
31+
1. __Plain React:__ Almost an exact copy of the ReactJS homepage example. This uses plain React
32+
code with no Firebase code at all. Changes made to this example are not persistent.
33+
34+
2. __React + Plain Firebase:__ A version of the first example with explicit Firebase calls. Changes
35+
made to this example are persistent.
36+
37+
3. __ReactFireMixin:__ A version of the first example which uses the ReactFireMixin. Changes made to
38+
this example are persistent.
39+
40+
Walkthrough
41+
-----------
42+
To learn more about how this example works, see the [blog post on the official Firebase blog](https://www.firebase.com/blog/2014-05-01-using-firebase-with-react.html).

0 commit comments

Comments
 (0)