typings
This commit is contained in:
parent
51e73aeeac
commit
7600029037
1 changed files with 9 additions and 1 deletions
|
|
@ -2,6 +2,7 @@
|
||||||
* @format
|
* @format
|
||||||
*/
|
*/
|
||||||
const Gun = require('gun')
|
const Gun = require('gun')
|
||||||
|
// @ts-ignore
|
||||||
Gun.log = () => {}
|
Gun.log = () => {}
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
require('gun/lib/open')
|
require('gun/lib/open')
|
||||||
|
|
@ -127,10 +128,17 @@ const Event = require('../event-constants')
|
||||||
* @prop {Record<string, any>} origBody
|
* @prop {Record<string, any>} origBody
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef {object} EncryptedEmission
|
||||||
|
* @prop {string} encryptedData
|
||||||
|
* @prop {string} encryptedKey
|
||||||
|
* @prop {string} iv
|
||||||
|
*/
|
||||||
|
|
||||||
// TO DO: move to common repo
|
// TO DO: move to common repo
|
||||||
/**
|
/**
|
||||||
* @typedef {object} SimpleSocket
|
* @typedef {object} SimpleSocket
|
||||||
* @prop {(eventName: string, data: Emission) => void} emit
|
* @prop {(eventName: string, data: Emission|EncryptedEmission) => void} emit
|
||||||
* @prop {(eventName: string, handler: (data: any) => void) => void} on
|
* @prop {(eventName: string, handler: (data: any) => void) => void} on
|
||||||
* @prop {{ query: { 'x-shockwallet-device-id': string }}} handshake
|
* @prop {{ query: { 'x-shockwallet-device-id': string }}} handshake
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue