The Veritone sample app is a minimal boilerplate for creating Veritone powered web applications (SPAs).
- Create React App for development and test infrastructure (see user guide)
- React + Redux for UI and declarative data fetching.
- node
^6.4.0
- yarn
^0.24.5
or npm^3.10.3
You can use nvm to easily switch Node versions between different projects.
We recommend using Yarn for dependency management, but npm install
will suffice.
$ yarn install # Install project dependencies (or `npm install`)
- Clone this repo and install the dependencies
git clone https://github.com/veritone/veritone-sample-app-react.git
cd veritone-sample-app-react/
yarn install
-
Create a local development alias in your
hosts
file for the new app.- edit
/etc/hosts
withsudo
using your preferred text editor - add:
127.0.0.1 local.veritone-sample-app.com
- edit
-
Create a Veritone developer account if you don't already have one.
-
Register a new Veritone application.
- URL:
http://local.veritone-sample-app.com:3000
- Oauth2 Redirect URL:
http://local.veritone-sample-app.com:3000/auth/veritone/callback
- URL:
-
In the files
.env
and.env.development
, fill in the CLIENT_ID, CLIENT_SECRET and CALLBACK_URL fields. These can be found by going to https://developer.veritone.com/applications and clicking your application in the table. The fields are shown underneath the application name at the top of the page. -
Start the development server
yarn start
- The sample app should now be serving at
http://local.veritone-sample-app.com:3000
.
$ yarn build # Build production assets (or `npm run build`)
We use git-flow to manage changes to this repository. To contribute to this project, please follow these steps:
- Create a fork of this repository on Github.
- Create a feature branch off the
develop
branch in your private fork. - Make your changes in your feature branch.
- When your features are ready, create a pull request from your feature branch in your private fork to the
develop
branch in this repo. - Once your pull request passes review, it will be merged into the
develop
branch.
Copyright 2018, Veritone Inc.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.