Skip to content

Commit b9c51b7

Browse files
committed
feat: update baselib defs to 2.26.0
1 parent 13c21b7 commit b9c51b7

File tree

6 files changed

+2887
-1434
lines changed

6 files changed

+2887
-1434
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## 2022-09-09 v3.6.0
2+
- 更新 API 定义到 2.26.0
3+
- 更改了部分监听方法及其参数的命名
4+
15
## 2022-06-24 v3.5.0
26
- 更新 API 定义到 2.24.6
37

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "miniprogram-api-typings",
3-
"version": "3.5.0",
3+
"version": "3.6.0",
44
"description": "Type definitions for APIs of Wechat Mini Program in TypeScript",
55
"main": "./index.d.ts",
66
"types": "./index.d.ts",

test/api-doc.test.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import { expectType } from 'tsd'
2-
type TPlatform = 'ios' | 'android' | 'windows' | 'mac'
32
// Test case from `Animation`
43
{
54
Page({
@@ -456,7 +455,7 @@ type TPlatform = 'ios' | 'android' | 'windows' | 'mac'
456455
const worker = wx.createWorker('workers/request/index.js') // 文件名指定 worker 的入口文件路径,绝对路径
457456

458457
worker.onMessage(function (res) {
459-
expectType<WechatMiniprogram.WorkerOnMessageCallbackResult>(res)
458+
expectType<WechatMiniprogram.WorkerOnMessageListenerResult>(res)
460459
})
461460
// 监听worker被系统回收事件
462461
worker.onProcessKilled(function () {
@@ -1024,6 +1023,8 @@ type TPlatform = 'ios' | 'android' | 'windows' | 'mac'
10241023
})
10251024
}
10261025

1026+
type TPlatform = 'ios' | 'android' | 'windows' | 'mac' | 'devtools'
1027+
10271028
// Test case from `wx.getSystemInfoSync`
10281029
{
10291030
wx.getSystemInfo({

types/wx/index.d.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ declare namespace WechatMiniprogram {
6363
type DynamicsCompressorNode = any
6464
type ScriptProcessorNode = any
6565
type PannerNode = any
66+
type AnalyserNode = any
6667
type AudioListener = any
6768
type WebGLTexture = any
6869
type WebGLRenderingContext = any

0 commit comments

Comments
 (0)