- Meteor.js (MongoDB and other packages will be installed automatically when you run meteor)
- OSX makes things infinitely simpler
- Google Chrome or another browser with a Javascript inspector
- [React Developer Tools] (https://chrome.google.com/webstore/detail/react-developer-tools/fmkadmapgofadopljbjfkapdkoienihi)
- [Robomongo 0.9.0 RC10] (https://robomongo.org/download)
-
git clone https://github.com/alan-xie/cs50seminar-meteor-react.git
-
Meteor.js Installation
- OSX
curl https://install.meteor.com/ | sh
- Windows
-
We need to install React dependencies that make our app work. In the
cs50seminar-meteor-react
directory, run this command in Terminal:meteor npm install --save react react-dom react-addons-pure-render-mixin react-addons-transition-group react-addons-css-transition-group react-addons-linked-state-mixin react-addons-create-fragment react-addons-update react-addons-test-utils react-addons-perf
-
Run
meteor
inside thecs50seminar-meteor-react
directory! -
Run
mongorestore --host 127.0.0.1 --port 3001 --db meteor dump/meteor
in thecs50seminar-meteor-react
directory. If you receive an error, you may have to right-click each of your existing collections in Robomongo and select "Drop Collection." Then, rerun themongorestore
command.
meteor
- In the Meteor app directory, runs the app
mongodump --host 127.0.0.1 --port 3001 --db meteor
- While
meteor
is running, dumps the entire database intodump/meteor
in the current directory
- While
mongorestore --host 127.0.0.1 --port 3001 --db meteor dump/meteor
- While
meteor
is running, restores a db from a dump in the formatdump/meteor
- While
mongoexport --host 127.0.0.1 --port 3001 --db meteor --collection titles --fields 'title,theatrical_release,domestic_gross,poster_url' --out titles.json
- While
meteor
is running, exports the collection called titles with a specific subset of fields totitles.json
- While
mongoimport --host 127.0.0.1 --port 3001 --db meteor --collection titles --file titles.json
- While
meteor
is running, imports the filetitles.json
to the collection called titles
- While
- [React Component Lifecycle] (https://facebook.github.io/react/docs/component-specs.html)
- [Meteor.publish and Meteor.subscribe] (https://www.meteor.com/tutorials/react/publish-and-subscribe)