Skip to content

Commit

Permalink
use remote data for production build (#165)
Browse files Browse the repository at this point in the history
* use remote data for production build

* Restyled by prettier (#166)

Co-authored-by: Restyled.io <commits@restyled.io>

Co-authored-by: restyled-io[bot] <32688539+restyled-io[bot]@users.noreply.github.com>
Co-authored-by: Restyled.io <commits@restyled.io>
  • Loading branch information
3 people committed Oct 21, 2020
1 parent 5058839 commit 7441ba9
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion apps/official/index.ts
Expand Up @@ -124,7 +124,10 @@ export const config: AppConfig = {
defaultVisual: "covmap",
datasources: {
"contact-index": {
url: (dateString) => `/data/districts_data_all.json`,
url: (dateString) =>
process.env.NODE_ENV === "production"
? `https://data.covmap.de/data/map-${dateString}.json`
: `/data/districts_data_all.json`,
},
},
visuals: {
Expand Down

0 comments on commit 7441ba9

Please sign in to comment.