fix(core): update

This commit is contained in:
2021-01-22 15:13:05 +00:00
parent 912b9bad51
commit a23c5a0fba
4 changed files with 26 additions and 32 deletions

View File

@ -69,12 +69,15 @@ export class TypedSocket {
serverUrlArg: string,
aliasArg = 'clientArg'
): Promise<TypedSocket> {
const domain = new plugins.smartstring.Domain(serverUrlArg);
const smartsocketClient = new plugins.smartsocket.SmartsocketClient({
alias: aliasArg,
role: publicRoleName,
password: publicRolePass,
port: 3000,
url: serverUrlArg,
port: domain.port || 3000,
url: `${domain.nodeParsedUrl.protocol}//${domain.nodeParsedUrl.host}`,
autoReconnect: true,
});
smartsocketClient.addSocketFunction(

View File

@ -10,8 +10,10 @@ export {
// @pushrocks scope
import * as isohash from '@pushrocks/isohash';
import * as smartsocket from '@pushrocks/smartsocket';
import * as smartstring from '@pushrocks/smartstring';
export {
isohash,
smartsocket
smartsocket,
smartstring
}