feat(plugin-sdk): init
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"name": "@proj-airi/plugin-sdk",
|
||||
"type": "module",
|
||||
"version": "0.8.4",
|
||||
"description": "Plugin SDK for Project AIRI",
|
||||
"author": {
|
||||
"name": "Moeru AI Project AIRI Team",
|
||||
"email": "airi@moeru.ai",
|
||||
"url": "https://github.com/moeru-ai"
|
||||
},
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/moeru-ai/airi.git",
|
||||
"directory": "packages/plugin-sdk"
|
||||
},
|
||||
"exports": {
|
||||
".": {
|
||||
"types": "./dist/index.d.mts",
|
||||
"default": "./dist/index.mjs"
|
||||
}
|
||||
},
|
||||
"main": "./dist/index.mjs",
|
||||
"types": "./dist/index.d.mts",
|
||||
"files": [
|
||||
"README.md",
|
||||
"dist",
|
||||
"package.json"
|
||||
],
|
||||
"scripts": {
|
||||
"dev": "pnpm run build",
|
||||
"build": "tsdown",
|
||||
"typecheck": "tsc --noEmit"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
console.warn('@proj-airi/plugin-sdk is currently working in progress. APIs may change without warning.')
|
||||
@@ -383,9 +383,9 @@ export function setupApp(options?: {
|
||||
}))
|
||||
|
||||
function closeAllPeers() {
|
||||
console.log('closing all peers', peers.size)
|
||||
logger.withFields({ totalPeers: peers.size }).log('closing all peers')
|
||||
for (const peer of peers.values()) {
|
||||
console.log('closing peer', peer.peer.id)
|
||||
logger.withFields({ peer: peer.peer.id, peerName: peer.name }).debug('closing peer')
|
||||
peer.peer.close?.()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user