Skip to content
Open
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
6 changes: 3 additions & 3 deletions REST/PhotoFrame/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Before you can run this sample, you must set up a Google Developers project and
1. Set up a Google Developers Project and enable the **Google Photos Library API**.
1. In your project, set up new OAuth credentials for a web server application. Set the authorized JavaScript origin to `http://127.0.0.1` and the authorized redirect URL to `http://127.0.0.1:8080/auth/google/callback` if you are running the app locally.
1. The console will display your authentication credentials. Add the `Client ID` and `Client secret` to the file `config.js`, replacing the placeholder values:
```
```node
// The OAuth client ID from the Google Developers console.
config.oAuthClientID = 'ADD YOUR CLIENT ID';

Expand All @@ -40,7 +40,7 @@ Make sure that you have configured the `Client ID` and the `Client secret` in th
Also check that the URLs configured for these credentials match how you access the server. By default this is configured for 127.0.0.1 (localhost) on port 8080.

You can also start the app with additional debug logging by setting the `DEBUG` environment variable to `true`. For example:
```
```properties
DEBUG=TRUE node app.js
```

Expand Down Expand Up @@ -69,4 +69,4 @@ When an album is selected, the handler `app.post('/loadFromAlbum', ...)` receive
## Displaying photos
Photos are displayed on the photo frame page of this app. The template file is located at `views/pages/frame.ejs`. When this page is loaded, a request is made to `app.get('/getQueue', ...)` to the server `app.js`.

This handler returns a list of the `mediaItems` the user has loaded into the frame through search or from an album. They are rendered for display by the browser through the file `static/js/frame.js`. Here the caption is constructed from the description and other media metadata. A thumbnail, scaled based on the original height and width, is used to render a preview initially while the image at full resolution is being loaded.
This handler returns a list of the `mediaItems` the user has loaded into the frame through search or from an album. They are rendered for display by the browser through the file `static/js/frame.js`. Here the caption is constructed from the description and other media metadata. A thumbnail, scaled based on the original height and width, is used to render a preview initially while the image at full resolution is being loaded.