{"id":18256483,"url":"https://github.com/baderlab/covid19-dashboard","last_synced_at":"2025-04-08T22:27:49.532Z","repository":{"id":72961812,"uuid":"251405389","full_name":"BaderLab/covid19-dashboard","owner":"BaderLab","description":null,"archived":false,"fork":false,"pushed_at":"2020-08-24T22:39:36.000Z","size":14818,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-02-14T17:42:52.957Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BaderLab.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-03-30T19:18:04.000Z","updated_at":"2021-06-02T14:03:35.000Z","dependencies_parsed_at":"2023-03-11T14:17:07.620Z","dependency_job_id":null,"html_url":"https://github.com/BaderLab/covid19-dashboard","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BaderLab%2Fcovid19-dashboard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BaderLab%2Fcovid19-dashboard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BaderLab%2Fcovid19-dashboard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BaderLab%2Fcovid19-dashboard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BaderLab","download_url":"https://codeload.github.com/BaderLab/covid19-dashboard/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247937515,"owners_count":21021277,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-05T10:22:08.746Z","updated_at":"2025-04-08T22:27:49.506Z","avatar_url":"https://github.com/BaderLab.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# COVID19 dashboard\n\n\n## Required software\n\n- [Node.js](https://nodejs.org/en/) ^12 for building the project\n- [Chrome](https://www.google.com/chrome/) for debugging\n\n\n## Getting started\n\n- Prerequisites:\n  - Node.js\n    - Option 1: Install [nvm](https://github.com/nvm-sh/nvm) so you can have multiple versions of node installed.\n      - Install version 12 with `nvm install 12`.\n      - Set version 12 as your default: `nvm alias default 12`.\n      - To use a particular version, do `nvm use 12.0.1` or set up a `.nvmrc` file in the CWD and do `nvm use`.\n    - Option 2: Install node manually:\n      - Mac: `brew install node@12`\n      - Linux: Use `dnf`, `zypper`, `apt`, etc.\n      - Or use [the installer](https://nodejs.org/en/download/) for Mac or Windows\n  - Chrome\n    - [Install Chrome](https://www.google.com/chrome/)\n    - Become familiar with the [debug tools](https://developers.google.com/web/tools/chrome-devtools/javascript/)\n- Start off by running `npm install`.\n- The main target you will run during development is `npm run watch`.\n  - This automatically builds the clientside code in the background.  The browser will refresh automatically when the code is rebuilt.\n- The Chrome debugger can be used for the clientside code (Chrome \u003e View \u003e Developer \u003e Developer Tools).  There is also an included launch config file that allows you to debug the client or the server directly in VSC.  Make sure to run `npm run watch` before opening the Chrome debugger.\n\n\n## Configuration\n\nThe following environment variables can be used to configure the server:\n\n- `NODE_ENV` : the environment mode, either `production` or `development` (default)\n- `PORT` : the port on which the server runs (default 3000)\n\n\n## Run targets\n\n- `npm start` : start the server (usually for prod mode)\n- `npm run watch` : watch mode (debug mode enabled, autorebuild, autoreload, server at [http://localhost:3000](http://localhost:3000))\n- `npm run build` : build project\n- `npm run build-prod` : build the project for production\n- `npm run bundle-profile` : visualise the bundle dependencies\n- `npm run clean` : clean the project\n- `npm run lint` : lint the project\n- `npm run test:mocha` : run model tests\n- `npm test` : run model tests, linting, and a build (run this before doing a pull request)\n\n## Running via Docker\n\nBuild the container.  Here, `covid19-dashabord` is used as the container name.\n\n```\ncd covid19-dashabord\ndocker build -t covid19-dashabord .\n```\n\nRun the container:\n\n```\ndocker run -it -p 12345:3000 -u \"node\" -e \"NODE_ENV=production\" --name \"covid19-dashabord\" covid19-dashabord\n```\n\nNotes:\n\n- The `-it` switches are necessary to make `node` respond to `ctrl+c` etc. in `docker`.\n- The `-p` switch indicates that port 3000 on the container is mapped to port 12345 on the host.  Without this switch, the server is inaccessible.\n- The `-u` switch is used so that a non-root user is used inside the container.\n- The `-e` switch is used to set environment variables.  Alternatively use `--env-file` to use a file with the environment variables.\n- References:\n  - [Dockerizing a Node.js web app](https://nodejs.org/en/docs/guides/nodejs-docker-webapp/)\n  - [Documentation of docker-node](https://github.com/nodejs/docker-node)\n  - [Docker CLI docs](https://docs.docker.com/engine/reference/commandline/cli/)\n\n\n\n## Testing\n\nAll files `/test` will be run by [Mocha](https://mochajs.org/).  You can `npm run test:mocha` to run all tests, or you can run `npm run test:mocha -- -g specific-test-name` to run specific tests.\n\n[Chai](http://chaijs.com/) is included to make the tests easier to read and write.\n\nBy running `npm test`, you will run the tests, the linting, and a test build.\n\n\n\n## Publishing a release\n\n1. Make sure the tests are passing: `npm test`\n1. Make sure the linting is passing: `npm run lint`\n1. Bump the version number with `npm version`, in accordance with [semver](http://semver.org/).  The `version` command in `npm` updates both `package.json` and git tags, but note that it uses a `v` prefix on the tags (e.g. `v1.2.3`).\n  1. For a bug fix / patch release, run `npm version patch`.\n  1. For a new feature release, run `npm version minor`.\n  1. For a breaking API change, run `npm version major.`\n  1. For a specific version number (e.g. 1.2.3), run `npm version 1.2.3`.\n1. Push the release: `git push origin --tags`\n1. Deploy the app: `npm run deploy`","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbaderlab%2Fcovid19-dashboard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbaderlab%2Fcovid19-dashboard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbaderlab%2Fcovid19-dashboard/lists"}