Skip to content
Switch branches/tags

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

React Project: MyReads

TypeScript code style: prettier tested with jest Build Status


This is the first project for the React Nanodegree.

Table of Contents

Getting started


This project was bootstrapped with Create React App.


  • Yarn package manager
  • create-react-app
  • Editor / IDE

To get started with this repository:

# git clone the repository e.g. into a <projects> folder
cd <projects>
# git clone with ssh
git clone
# or git clone with HTTPS
git clone

# change directory into the cloned repo
cd myreads

# install the dependencies


How to run

# Navigate into your local myreads project directory
cd <projects>/myreads

# To run the development server
yarn start

If there appears to be issues with dependencies not being installed, or up to date, then run yarn.

Backend Server API

Instructions from Udacity on how to use the API:

To simplify your development process, we've provided a backend server for you to develop against. The provided file BooksAPI.js contains the methods you will need to perform necessary operations on the backend:


Method Signature:

  • Returns a Promise which resolves to a JSON object containing a collection of book objects.
  • This collection represents the books currently in the bookshelves in your app.


Method Signature:

update(book, shelf)
  • book: <Object> containing at minimum an id attribute
  • shelf: <String> contains one of ["wantToRead", "currentlyReading", "read"]
  • Returns a Promise which resolves to a JSON object containing the response data of the POST request


Method Signature:

search(query, maxResults)
  • query: <String>
  • maxResults: <Integer> Due to the nature of the backend server, search results are capped at 20, even if this is set higher.
  • Returns a Promise which resolves to a JSON object containing a collection of book objects.
  • These books do not know which shelf they are on. They are raw results only. You'll need to make sure that books have the correct state while on the search page.

Search Terms

The backend API uses a fixed set of cached search results and is limited to a particular set of search terms (see Search Terms below). That list of terms are the only terms that will work with the backend, so don't be surprised if your searches for Basket Weaving or Bubble Wrap don't come back with any results.

'Android', 'Art', 'Artificial Intelligence', 'Astronomy', 'Austen', 'Baseball', 'Basketball', 'Bhagat', 'Biography', 'Brief', 'Business', 'Camus', 'Cervantes', 'Christie', 'Classics', 'Comics', 'Cook', 'Cricket', 'Cycling', 'Desai', 'Design', 'Development', 'Digital Marketing', 'Drama', 'Drawing', 'Dumas', 'Education', 'Everything', 'Fantasy', 'Film', 'Finance', 'First', 'Fitness', 'Football', 'Future', 'Games', 'Gandhi', 'Homer', 'Horror', 'Hugo', 'Ibsen', 'Journey', 'Kafka', 'King', 'Lahiri', 'Larsson', 'Learn', 'Literary Fiction', 'Make', 'Manage', 'Marquez', 'Money', 'Mystery', 'Negotiate', 'Painting', 'Philosophy', 'Photography', 'Poetry', 'Production', 'Programming', 'React', 'Redux', 'River', 'Robotics', 'Rowling', 'Satire', 'Science Fiction', 'Shakespeare', 'Singh', 'Swimming', 'Tale', 'Thrun', 'Time', 'Tolstoy', 'Travel', 'Ultimate', 'Virtual Reality', 'Web Development', 'iOS'


Jest is used for tests. To run the test suite, use this command:

yarn test

Continuous Integration

It's complete overkill for this project but I added Travis CI to the project. A commit pushed to origin/<branch> triggers a build on Travis.

The .travis.yml file includes the CI build config. The .nvmrc file is used to specify the version of Node used in the project and for the CI build.

Style Guide

This repo uses ESLint with Prettier formatting.

The ESLint config extends from AirBnB, with a few changes. Refer to the .eslintrc.yml file in the root of the repo for info on the changes.



# from the project root:
yarn build


The demo app is deployed with Now. These are the instructions to deploy with now.

# from the project root:
yarn build

cd build

now --name your-project-name

# for example:
now --name cubiio-myreads
> Ready! (copied to clipboard) [6s]

Paste that URL into your browser when the build is complete, and you will see your deployed app.


The demo app is currently live here.


Main Page

Search Page


Udacity React Nanodegree project: Single Page Application built with React and React Router.




No packages published