内容简介:JavaScript Library for Google Sheets/Microsoft Excel Online through sheet2api.The sheet2api JS library can be installed through npm.To get started you need to provide your sheet2api Spreadsheet API URL. You can find it on the
sheet2api JavaScript Client
JavaScript Library for Google Sheets/Microsoft Excel Online through sheet2api. https://sheet2api.com/
Installation
The sheet2api JS library can be installed through npm.
npm install sheet2api-js --save
Example Usage
To get started you need to provide your sheet2api Spreadsheet API URL. You can find it on the sheet2api Dashboard .
Try it out with the codepen https://codepen.io/sheet2api/pen/MWKZrqW
Importing the library
<!-- Server import --> <script src="//sheet2api.com/v1/api.js"></script>
// Or, Require import
var Sheet2API = require('sheet2api-js');
// Or, ES6 import
import Sheet2API from 'sheet2api-js';
Read rows
<script src="//sheet2api.com/v1/api.js"></script>
<script>
var url = 'https://sheet2api.com/v1/FgI6zV8qT121/characters/';
var options = {};
Sheet2API.read(url, options).then(function(result){
console.log(result);
}, function(error){
console.log(error);
});
</script>
Read rows matching a search query
<script src="//sheet2api.com/v1/api.js"></script>
<script>
var url = 'https://sheet2api.com/v1/FgI6zV8qT121/characters/';
var options = {query: { 'Name': 'Bugs Bunny' }};
Sheet2API.read(url, options).then(function(result){
console.log(result);
}, function(error){
console.log(error);
});
</script>
Create new rows
<script src="//sheet2api.com/v1/api.js"></script>
<script>
var url = 'https://sheet2api.com/v1/FgI6zV8qT121/characters/';
var newRowData = { "Favourite Thing": "Carrots", "Name": "Bugs Bunny" };
var options = {};
Sheet2API.write(url, options, newRowData).then(function(result){
console.log(result);
}, function(error){
console.log(error);
});
</script>
Something missing you'd like to see? Please create an issue.
很遗憾的说,推酷将在这个月底关闭。人生海海,几度秋凉,感谢那些有你的时光。
以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,也希望大家多多支持 码农网
猜你喜欢:本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
深入理解计算机系统(英文版·第2版)
[美] Randal E. Bryant、[美] David R. O'Hallaron / 机械工业出版社 / 2011-1 / 128.00元
本书是一本将计算机软件和硬件理论结合讲述的经典教程,内容覆盖计算机导论、体系结构和处理器设计等多门课程。本书的最大优点是为程序员描述计算机系统的实现细节,通过描述程序是如何映射到系统上,以及程序是如何执行的,使读者更好地理解程序的行为为什么是这样的,以及造成效率低下的原因。 相对于第1版,本版主要是反映了过去十年间硬件技术和编译器的变化,具体更新如下: 1. 对系统的介绍(特别是实际使......一起来看看 《深入理解计算机系统(英文版·第2版)》 这本书的介绍吧!