stream-chat
Advanced tools
Comparing version 0.13.6 to 0.13.7
{ | ||
"name": "stream-chat", | ||
"version": "0.13.6", | ||
"version": "0.13.7", | ||
"description": "JS SDK for the Stream Chat API", | ||
@@ -38,3 +38,3 @@ "author": "GetStream", | ||
"@babel/runtime": "^7.3.1", | ||
"axios": "^0.18.0", | ||
"axios": "^0.18.1", | ||
"chai-arrays": "^2.0.0", | ||
@@ -41,0 +41,0 @@ "cross-fetch": "^3.0.0", |
@@ -53,4 +53,39 @@ // TypeScript Version: 2.2 | ||
export interface StreamChatOptions { | ||
/** | ||
* extraData contains tags array attached to log message. Tags can have one/many of following values: | ||
* 1. api | ||
* 2. api_request | ||
* 3. api_response | ||
* 4. client | ||
* 5. channel | ||
* 6. connection | ||
* 7. event | ||
* | ||
* It may also contains some extra data, some examples have been mentioned below: | ||
* 1. { | ||
* tags: ['api', 'api_request', 'client'], | ||
* url: string, | ||
* payload: object, | ||
* config: object | ||
* } | ||
* 2. { | ||
* tags: ['api', 'api_response', 'client'], | ||
* url: string, | ||
* response: object | ||
* } | ||
* 3. { | ||
* tags: ['event', 'client'], | ||
* event: object | ||
* } | ||
* 4. { | ||
* tags: ['channel'], | ||
* channel: object | ||
* } | ||
*/ | ||
logger?(log_level: 'info' | 'error', message: string, extraData?: object): void; | ||
[propName: string]: any; | ||
} | ||
export class StreamChat { | ||
constructor(key: string, secretOrOptions?: string, options?: object); | ||
constructor(key: string, secretOrOptions?: string, options?: StreamChatOptions); | ||
@@ -57,0 +92,0 @@ devToken(userID: string): string; |
@@ -6,3 +6,6 @@ import { StreamChat } from 'stream-chat'; | ||
const client = new StreamChat(apiKey, null, { timeout: 3000 }); // $ExpectType StreamChat | ||
const client = new StreamChat(apiKey, null, { | ||
timeout: 3000, | ||
logger: (logLevel: string, msg: string, extraData: {}) => {}, | ||
}); // $ExpectType StreamChat | ||
@@ -9,0 +12,0 @@ const devToken = client.devToken('joshua'); // $ExpectType string |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1687162
19602
11
Updatedaxios@^0.18.1