Skip to content
Discussion options

You must be logged in to vote

I'd probably do something like _data/all_time.js or _data/seasons/all_time.js and have that file do a const s2022 = require("./s2022.json") (or maybe even something w/ https://www.npmjs.com/package/require-dir) and then do all your calculations in Node (instead of Nunjucks).
Then your final export is just the calculated data which you can loop over.

Replies: 1 comment 10 replies

Comment options

You must be logged in to vote
10 replies
@pdehaan
Comment options

pdehaan Nov 12, 2022
Collaborator

@pdehaan
Comment options

pdehaan Nov 12, 2022
Collaborator

@SteGreig
Comment options

@pdehaan
Comment options

pdehaan Nov 12, 2022
Collaborator

@SteGreig
Comment options

Answer selected by SteGreig
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants