From baf06fe8a7e34f9d785c341134543a5c1dcb8a68 Mon Sep 17 00:00:00 2001 From: Mateusz Mandera Date: Sun, 15 Oct 2023 02:18:44 +0200 Subject: [PATCH] docs: Rename references to stats.js to stats.ts in the analytics doc. That file has been migrated to typescript. --- docs/subsystems/analytics.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/subsystems/analytics.md b/docs/subsystems/analytics.md index 90718426e2..c18ce78c15 100644 --- a/docs/subsystems/analytics.md +++ b/docs/subsystems/analytics.md @@ -179,7 +179,7 @@ The relevant files are: - `analytics/views/stats.py`: All chart data requests from the /stats page call get_chart_data in this file. -- `web/src/stats/stats.js`: The JavaScript and Plotly code. +- `web/src/stats/stats.ts`: The JavaScript and Plotly code. - `templates/analytics/stats.html` - `web/styles/stats.css` and `web/styles/portico.css`: We are in the process of re-styling this page to use in-app css instead of portico css, @@ -190,11 +190,11 @@ The relevant files are: Most of the code is self-explanatory, and for adding say a new graph, the answer to most questions is to copy what the other graphs do. It is easy when writing this sort of code to have a lot of semi-repeated code blocks -(especially in `stats.js`); it's good to do what you can to reduce this. +(especially in `stats.ts`); it's good to do what you can to reduce this. Tips and tricks: -- Use `$.get` to fetch data from the backend. You can grep through `stats.js` +- Use `$.get` to fetch data from the backend. You can grep through `stats.ts` to find examples of this. - The Plotly documentation is at (check out the full reference, event