-
Copy the contents of the
.env.example
to a.env
file in the root of the project before starting the app.The values provided in the
env.example
file are enough to get the app running to perform the basic search. -
To use Github Oauth, you'd need a Github clientId and secret which I haven't included in this repo. I'm happy to provide those once you need them. You'd also need so start a nodejs server which would help with the authentication flow.
For this, you'd need to run the
yarn run:all
command. This would launch both the client and server app.
In the project directory, you can run:
Runs the client app in the development mode. Open http://localhost:3000 to view it in the browser.
Runs the node server that handles Github OAuth in development mode. The api is available on http://localhost:3001.
Launches both the client and server applications so you can easily test the OAuth flow.
Launches the unit test runner in the interactive watch mode. See the section about running tests for more information.
Runs Cypress tests to completion. By default, cypress run will run all tests headlessly in the Electron browser.
Launches the Cypress test runner.
Builds the app for production to the build
folder.
It correctly bundles React in production mode and optimizes the build for the best performance.
The build is minified and the filenames include the hashes.
-
Implementing Github OAuth came with a few challenges.
The API doesn't support CORS requests from the browser
To resolve this, I had to create a NODEJS server to make the authentication request to retrieve the
access_token
- Fix console warnings introduced by React LazyLoad library