This repo is 10 years old -- yikes, seems like only yesterday!
Check out this Observable template instead: Google Sheets Starter
These demos retrieve data as CSV from a Google spreadsheet.
To adapt a demo to another spreadsheet:
- You must share the spreadsheet so that "Anyone with the link can view" it.
- You need a unique spreadsheet key (the long string
1Cj1...ieYo
in the URL above). You can get the key from the "shareable link" when you share a spreadsheet, or from the URL in the address bar when you edit the spreadsheet in a browser.
Modify the demos with Google's Query Language.
D3 (CORS):
- This demo uses Google's CORS-enabled services. This is the preferred and simpler approach.
D3 (JSONP):
- This demo implements a D3 plugin that uses JSONP. It can use non-CORS-enabled Google services. But JSONP has security issues, so beware.
Python (3):
$ python app.py
Node.js:
$ node app.js