Skip to content

rovercode/rovercode-ui

Repository files navigation

License: GPL v3 Chat Build Status Coverage Status

Rovercode User Interface

This repository contains the react application frontend for the Rovercode web application.

Requirements

nodejs LTS version v10.x or v12.x is required

yarn is required for installing dependencies. Instructions for installing yarn can be found here.

Dependencies

To install the production dependencies (for just running the application), run:

yarn install --pure-lockfile --production

To install development dependencies (for running tests, lint, etc), run:

yarn install --pure-lockfile

Running

NOTE: The application running the development webserver requires the rovercode api to be running at http://localhost:8000

To run the development web server using a locally running API instance, run:

yarn start:local

To run the development web server using the API instance on alpha.rovercode.com, run:

yarn start:alpha

Unit Testing

To run unit tests, run:

yarn test

To debug the tests in VS Code, use these run configurations in your launch.json:

{
  "version": "0.2.0",
  "configurations": [
    {
      "type": "node",
      "request": "launch",
      "name": "Jest All",
      "program": "${workspaceFolder}/node_modules/.bin/jest",
      "args": [
        "--runInBand"
      ],
      "console": "integratedTerminal",
      "internalConsoleOptions": "neverOpen",
      "disableOptimisticBPs": true,
      "windows": {
        "program": "${workspaceFolder}/node_modules/jest/bin/jest",
      }
    },
    {
      "type": "node",
      "request": "launch",
      "name": "Jest Current File",
      "program": "${workspaceFolder}/node_modules/.bin/jest",
      "args": [
        "${fileBasenameNoExtension}"
      ],
      "console": "integratedTerminal",
      "internalConsoleOptions": "neverOpen",
      "disableOptimisticBPs": true,
      "windows": {
        "program": "${workspaceFolder}/node_modules/jest/bin/jest",
      }
    }
  ]
}

Linting

To run the linter, run:

yarn lint