Closed steven-pribilinskiy closed 10 years ago
Hi Steven,
So here's the crux of the new-spreadsheet-feature
branch:
var steps = [];
if(opts.spreadsheetCreate) {
var documents = new Documents(opts);
steps.push(documents.auth);
steps.push(documents.createSheet);
}
//perform operations on spreadsheet
var spreadsheet = new Spreadsheet(opts);
steps.push(spreadsheet.auth);
steps.push(spreadsheet.init);
async.series(steps, callback);
The stable branch is essentially just the "perform operations on spreadsheet" portion (using callbacks instead of async.series
). This branch adds the an extra few steps to create the spreadsheet before handing back the spreadsheet object.
Next, some of the Spreadsheet class's methods we're moved into base.js
(a parent abstract class), and now spreadsheet.js
and document.js
inherit from base.js
.
Since the branch is 20 commits behind, I'd say the easiest thing to do is understand both branches and then implement the above described changes.
Cheers Jaime
Sorry, i was not clear enough. I meant the New Google Sheets version https://www.youtube.com/watch?v=9AyoRkr4I3U
it turned out that the culprit is the Gdata API that is not supported yet in the New Sheets https://support.google.com/drive/answer/3543688
Nevertheless ability to create new Sheets/Docs will be a nice feature as i've already switched back to the "Old" sheets ;)
From a stackoverflow answer March 28th 2014:
"It appears that Google has finally updated their Gdata APIs to work with the new sheets now. Notice that the page: https://support.google.com/drive/answer/3543688 has removed the line about Gdata not working..."
Decided to switch to the New Sheets version but it turned out that the wonderful node module doesn't support New Sheets yet. Are there lots of changes involved to implement it?
Thanks