Skip to content

Commit

Permalink
[rnl] updates url paths, more cleanup and polish, runs update-data fo…
Browse files Browse the repository at this point in the history
…r the latest, guards against missing data
  • Loading branch information
Jimmy Lee committed Jul 9, 2017
1 parent 6a5edf0 commit 44b00ec
Show file tree
Hide file tree
Showing 22 changed files with 696 additions and 646 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ config.js
.next
scripts/raw-github-results.json
secrets.json
npm-debug.log
26 changes: 16 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,35 @@
# Native Directory

This is the repository for the code that runs http://native.directory. Native Directory is a website where you can look up repositories that are compatible with React Native.
Native Directory is a website where you can see all of the libraries that are compatible with React Native.

Visit https://www.native.directory/ to check it out.

You are at the right place if:

- You made a repository on GitHub and you want the world to know it works with React Native.
- You want to submit a pull request to improve Native Directory.
- You want to report a bug or make a suggestion.

## Setup
## Setup and run locally

You'll need the following on your computer to run this site locally
Prerequisites

- Node 7.9.0+

To start the website in development mode, run:
Commands

```sh
npm install
npm run dev
```

You should be able to visit `localhost:8000` in your browser.

## Update site data

To update data, you'll need to create a json file called `secrets.json` in the same folder as package.json. To get a GitHub client id and secret, you'll have to visit: https://github.com/settings/developers while logged in.
* To update site data you need to provide a couple of keys in a file called `secrets.json`.
* You must create your own `secrets.json` in the root directory of the repo.
* Visit https://github.com/settings/developers to get your keys.

```json
{
Expand All @@ -33,18 +39,18 @@ To update data, you'll need to create a json file called `secrets.json` in the s

```

Once you have completed this step, run:
This command creates site data in `./build/data.json`

```
npm run create-data
```

A new data set will be available in `build/data.json`.

## Deploy to production

The site is hosted on Heroku, only @jimmylee can run this command at the moment to deploy to native.directory. But if you have your own Heroku server you can deploy this website too.
* Site is hosted on Heroku.
* Only @jimmylee (and maybe @brentvatne) can deploy to https://www.native.directory/
* You can deploy your own.

```
```sh
git push heroku master
```
Loading

0 comments on commit 44b00ec

Please sign in to comment.