This is a Next.js project bootstrapped with create-next-app
.
First, run the development server:
npm run dev
Open http://localhost:3000 with your browser to see the result.
We have a Google Spreadsheet with data about Repair Cafés we couldn't find elsewhere. In the future we hope to move this into a database and make it editable by the Repair Café organizers using their own logins.
It contains the columns mentioned in the RC
type (see Types) + the ones that are put nested under links see LINK_COLUMNS in update-data.
We export it's data, combine it with the sources below and save it into a json file by running:
npm run update-data
For this to work you'll need to create a service account, duplicate .env.local.example
to .env.local
fill in GOOGLE_PRIVATE_KEY
GOOGLE_PRIVATE_KEY
and give the the service account access to your spreadsheet.
More info: https://theoephraim.github.io/node-google-spreadsheet/#/guides/authentication
We use openholidaysapi.org to retrieve accurate dates on public and school holidays. We download it to a json to prevent being directly dependant on it for the function of the website. It enables downloading 3 years into the future, so ones in a while we need to run the update data script. To update the data run:
npm run update-holidays-data
We use api.aladhan.com to retrieve Ramadan dates. We download it to a json to prevent being directly dependant on it for the function of the website. It enables downloading 5 years into the future, so ones in a while we need to run the update data script. To update the data run:
npm run update-ramadan-data
We use the repair.org API to pull in the coordinates they know. We download it to a json to prevent being directly dependant on it for the function of the website. To update that data run:
npm run update-map-data
For the Repair Cafés that are not on repair.org or for when we want to override their coordinates we can store the coordinates in manual-map-data.json
. When the update-data
is run it first checks manual-map-data.json
, if none are found it checks the Repair Cafés map data and when it still can't find coordinates it will add an entry to manual-map-data.json
so it can be filed in.
A site like https://www.latlong.net/ can be used to find coordinates.
dev
Start in development mode.build
Build for production usage.build:analyze
Build for production usage and analyze the bundle.start
Start a Next.js production server, using build code.test
Execute unit tests.test:watch
Watching test files to automatically run unit tests.
To learn more about Next.js, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
You can check out the Next.js GitHub repository - your feedback and contributions are welcome!
The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.
Check out our Next.js deployment documentation for more details.