@roomservice/browser
Advanced tools
Comparing version 0.4.3 to 0.4.4-0
@@ -0,0 +0,0 @@ interface RoomValue { |
export {}; |
@@ -0,0 +0,0 @@ import RoomClient from "./room-client"; |
export {}; |
export declare const ROOM_SERICE_SOCKET_URL = "https://api.roomservice.dev"; |
@@ -1,6 +0,5 @@ | ||
import { Obj, Room, Session } from "./types"; | ||
import { Obj, Room, Session } from './types'; | ||
export default class DocClient<T extends Obj> { | ||
private readonly _peer; | ||
private readonly _roomReference; | ||
private readonly _authorizationUrl; | ||
private _socket?; | ||
@@ -17,3 +16,2 @@ private _roomId?; | ||
constructor(parameters: { | ||
authUrl: string; | ||
roomReference: string; | ||
@@ -31,3 +29,3 @@ defaultDoc?: T; | ||
*/ | ||
init({ room, session }: { | ||
init({ room, session, }: { | ||
room?: Room; | ||
@@ -34,0 +32,0 @@ session?: Session; |
import RoomServiceClient from "./client"; | ||
export default RoomServiceClient; |
@@ -1,6 +0,8 @@ | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
const tslib_1 = require("tslib"); | ||
const client_1 = tslib_1.__importDefault(require("./client")); | ||
exports.default = client_1.default; | ||
//# sourceMappingURL=index.js.map | ||
'use strict' | ||
if (process.env.NODE_ENV === 'production') { | ||
module.exports = require('./browser.cjs.production.min.js') | ||
} else { | ||
module.exports = require('./browser.cjs.development.js') | ||
} |
@@ -0,0 +0,0 @@ /** |
@@ -0,0 +0,0 @@ import { Room, Session } from "./types"; |
@@ -0,0 +0,0 @@ import { PresenceMeta } from "./presence-client"; |
/// <reference types="socket.io-client" /> | ||
declare const Sockets: { | ||
newSocket(url: string, opts: SocketIOClient.ConnectOpts): SocketIOClient.Socket; | ||
on(socket: SocketIOClient.Socket, event: "error" | "connect" | "disconnect" | "sync_room_state" | "update_presence", fn: (...args: any[]) => void): void; | ||
on(socket: SocketIOClient.Socket, event: "connect" | "disconnect" | "error" | "sync_room_state" | "update_presence", fn: (...args: any[]) => void): void; | ||
emit(socket: SocketIOClient.Socket, event: "sync_room_state" | "update_presence", ...args: any[]): void; | ||
@@ -6,0 +6,0 @@ disconnect(socket: SocketIOClient.Socket): void; |
@@ -0,0 +0,0 @@ /** |
@@ -0,0 +0,0 @@ import nock from "nock"; |
@@ -0,0 +0,0 @@ export declare type Obj = { |
{ | ||
"name": "@roomservice/browser", | ||
"version": "0.4.3", | ||
"main": "dist/index", | ||
"types": "dist/index", | ||
"version": "0.4.4-0", | ||
"license": "MIT", | ||
"main": "dist/index.js", | ||
"typings": "dist/index.d.ts", | ||
"files": [ | ||
@@ -10,11 +10,26 @@ "dist" | ||
"scripts": { | ||
"build": "rm -rf ./dist && tsc", | ||
"clean": "rm -rf ./dist", | ||
"compile": "tsc -p tsconfig.build.json", | ||
"prepublishOnly": "yarn run build", | ||
"test": "jest" | ||
"start": "tsdx watch", | ||
"build": "tsdx build", | ||
"test": "tsdx test", | ||
"lint": "tsdx lint", | ||
"prepare": "tsdx build" | ||
}, | ||
"peerDependencies": {}, | ||
"husky": { | ||
"hooks": { | ||
"pre-commit": "tsdx lint" | ||
} | ||
}, | ||
"prettier": { | ||
"printWidth": 80, | ||
"semi": true, | ||
"singleQuote": true, | ||
"trailingComma": "es5" | ||
}, | ||
"name": "@roomservice/browser", | ||
"author": "Evan Conrad", | ||
"module": "dist/browser.esm.js", | ||
"devDependencies": { | ||
"@types/invariant": "^2.2.30", | ||
"@types/jest": "^24.0.23", | ||
"@types/jest": "^25.1.3", | ||
"@types/lodash": "^4.14.149", | ||
@@ -25,7 +40,9 @@ "@types/node": "^12.12.17", | ||
"@types/uuid": "^3.4.6", | ||
"husky": "^4.2.3", | ||
"jest": "^24.9.0", | ||
"nock": "^11.7.0", | ||
"ts-jest": "^24.2.0", | ||
"tslib": "^1.10.0", | ||
"typescript": "^3.7.5" | ||
"tsdx": "^0.12.3", | ||
"tslib": "^1.11.1", | ||
"typescript": "^3.8.3" | ||
}, | ||
@@ -44,7 +61,3 @@ "dependencies": { | ||
"uuid": "^3.3.3" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/getroomservice/browser" | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
No contributors or author data
MaintenancePackage does not specify a list of contributors or an author in package.json.
Found 1 instance in 1 package
258774
1651
1
14
24
3
8
1