PathwayCommons / hyper-recent

Hyper-recent article feed
MIT License
1 stars 0 forks source link

Do not hardcode topics #31

Closed jvwong closed 1 year ago

jvwong commented 1 year ago

The goal of this PR is to ensure no topic-specific details are harcoded. Rather, the details of each topic are defined in the raw JSON file consumed by the app. Eventually, such a file would be packaged alongside the app, and regenerated automatically (GitHub action) and regularly (CRON job, e.g. every night).

Sample schema for data file:

[
  {
    "id": "alzheimers-disease",
    "name": "Alzheimer's Disease",
    "description": "Latest research reports about AD in the clinic and at the bench.",
    "img": "data:image/jpeg;base64,/9j/....",
    "papers": [
       {
          "id": "10.1101/2022.10.26.22281539",
          "doi": "10.1101/2022.10.26.22281539",
          "title": "Directed functional brain connectivity is altered in sub-threshold amyloid-β accumulators",
          "journal": "medrxiv",
          "date": "2022-10-27T00:00:00.000Z",
          "brief": null,
          "authors": "Mijalkov, M.; Vereb, D.; Canal-Garcia, A.; Volpe, G.; Pereira, J.; Alzheimer's Disease Neuroimaging Initiative, "
        },
        ...
      ],
  },
  ...
]

Notes:

Refs #22