npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

tadcode-wpsjs

v0.3.2

Published

## 基于wps官方文档 - [**AirScript文档**](https://airsheet.wps.cn/docs/apitoken/intro.html) - [**WPS多维表格:“开发”功能使用说明文档**](https://365.kdocs.cn/l/ctzsgDlAGF0l) - [**执行AirScript脚本操作使用指南**](https://365.kdocs.cn/l/cdQOqc6TZuMk) - [**快速入门多维表“开发”**](https://365.kdocs.cn/

Readme

tadcode-wpsjs

基于wps官方文档

联系我

如你有业务需要wps代码服务,可以点此联系我,三个工作日内必定回复。

如您公司存在敏感信息业务,需要长期人才,亦可来讯商谈。

扫一扫联系我

应用

用于学习wpsjs-api,远程调用wpsjs-api。

使用wpsjs-api。支持异步任务。

在远程部署代码好代码,通过传输的调用信息进行调用api。原理是使用代理收集调用信息,之后让远程代码进行调用并且返回结果。

远程代码在tadcode-wpsjs/remoteCode目录的index.js文件中。将其复制粘贴到对应webhook的脚本中才能支持wpsjsGlobal的调用。

安装

npm install tadcode-wpsjsbun install tadcode-wpsjs

获取脚本令牌和webhook链接

获取脚本令牌

脚本令牌

webhook链接

!!!webhook链接的脚本内容必须部署为tadcode-wpsjs/remoteCode/index.js中的脚本内容。

webhook链接

案例

获取当前多维表的所有表格信息

import { initRemoteCallWpsjsGlobal } from 'tadcode-wpsjs'
/* 脚本令牌 具体获取方式参考上面 */
const scriptToken = 'xxxx'
/* webhook url地址 具体获取方式参考上面 */
const webhookURL = 'xxxx'
const wpsjsGlobal = initRemoteCallWpsjsGlobal({ scriptToken, webhookURL,  })
const data = await wpsjsGlobal.Application.Sheet.GetSheets().execution()
console.log(data)

对于智能表格执行赋值操作

import { initRemoteCallWpsjsGlobal } from 'tadcode-wpsjs'
/* 脚本令牌 具体获取方式参考上面 */
const scriptToken = 'xxxx'
/* webhook url地址 具体获取方式参考上面 */
const webhookURL = 'xxxx'
const wpsjsGlobal = initRemoteCallWpsjsGlobal({ scriptToken, webhookURL,  })
const values = [
  ['name', 'price'],
  ['米', 2.5],
]
function setValue(data: any[][], rangeReference = 'a1') {
  const rowCount = data.length
  const columnCount = data[0].length
  wpsjsGlobal.Application.ActiveSheet.Range(rangeReference).Resize(rowCount, columnCount).Value2 = data
  return wpsjsGlobal.execution() as unknown as boolean
}
setValue(values)

执行脚本并且返回(不用部署remoteCode代码)

import { execution } from 'tadcode-wpsjs'
/* 脚本令牌 具体获取方式参考上面 */
const scriptToken = 'xxxx'
/* webhook url地址 具体获取方式参考上面 */
const webhookURL = 'xxxx'
const result=await execution({ scriptToken, webhookURL })
const data =await result.json()
console.log(data)

支持

如果对你有用请在gitcode给个star