You will need to create Google service account credentials and give it access to a spreadsheet. Then those values must be placed in a .env
file in the root directory.
GOOGLE_CREDENTIALS="{\"type\": \"service_account\", ... }"
GOOGLE_SPREADSHEET_ID="TlkLIEsS9Twtb02z34Df1lYtyrfssM22-1DKfFeV5GB4"
Spreadsheet must adhere to the following format otherwise UI will break. Note: The date format does not matter, will be converted to a number in the response.
Date | Location Name | Image Url | Featured | Description |
---|---|---|---|---|
2022-04-13 | Ground Up Cafe | https://placekitten.com/150/150?image=7 | FALSE | Best matcha latte! |
Then you can run the following to work locally.
$ pnpm install
$ pnpm start
In the project directory, you can run:
Runs the app in the development mode.
Open http://localhost:8888 to view it in the browser.
The page will reload if you make edits.
Builds the app for production to the dist
folder.
The build is minified and the filenames include the hashes.
Your app is ready to be deployed!
Currently the only test is one used to output fake CSV data in a snapshot, which then can be copied into a CSV file and imported to Google Sheets.
You can deploy the dist
and functions
folders to Netlify, though the easiest method would be through the CLI tool. Make sure to set the ENV variables as well.