Partial implementation of Quiltr using React
- Bootstrapped using
create-react-app
react-router
react-bootstrap
bootstrap
react-fontawesome
- Free dynos on Heroku (where the API is hosted) can be very slow to spin up. The first time you load the page, it will take a minute to grab the initial set of data; subsequent calls will be much more reasonable. If you'd prefer to run the API locally, code and setup instructions are at
rhjones/quiltr-api
. - I'm redirecting from
/
to/patterns
automatically because, for this implementation, having a mostly content-less index/root view didn't seem to make sense. - I'm currently using
hashHistory
instead ofbrowserHistory
for easier deployment to GH Pages.rafrex/spa-github-pages
looks like a reasonable solution to this problem, but I haven't yet pursued this in the interest of time. - I initially developed my API to work with Ember and
ember-data
, which initiates requests for related data based on models defined in the app. I've written a fairly clunky promise chain in the ProjectCard component that fetches the user and image associated with a particular project after first getting that project and the related user/image IDs, but I suspect there are several better ways to handle this—throughredux
, or perhaps withPromise.all
and an array of URLs. ThecomponentDidMount()
method in lines 23-46 of this component is the least DRY/concise bit of code in the project.