google-sheets-parser
v1.0.0
Published
Parses a Google sheet and returns data as a JavaScript array.
Downloads
7
Maintainers
Readme
Google Sheets Parser
Parses Google sheets and returns data in a structured JavaScript array.
Installation
Yarn
$ yarn add google-sheets-parser
NPM
$ npm install google-sheets-parser
Usage
CommonJS require
const GoogleSheetsParser = require('google-sheets-parser').default;
const parser = new GoogleSheetsParser(
spreadsheetId,
sheetName,
oauthCredentials,
);
// This must be in an async function
const data = await parser.parse();
console.log(data);
ES6 import
import GoogleSheetsParser from 'google-sheets-parser';
const parser = new GoogleSheetsParser(
spreadsheetId,
sheetName,
oauthCredentials,
);
// This must be in an async function
const data = await parser.parse();
console.log(data);