new PluginBtp({
server: 'btp+wss://account:secret@example.com'
})
You can say
new PluginBtp({
server: 'btp+wss://example.com',
btpAccount: 'account',
btpToken: 'secret'
})
This especially fixes some issues we've seen in browsers, where some won't parse a URL that has an empty username field (i.e. btp+wss://:secret@example.com)
The names btpAccount and btpToken were chosen because they are unlikely to collide with the identifiers in any subclass (this._account is used by some children of plugin btp)
Now, in addition to saying
You can say
This especially fixes some issues we've seen in browsers, where some won't parse a URL that has an empty username field (i.e.
btp+wss://:secret@example.com
)The names
btpAccount
andbtpToken
were chosen because they are unlikely to collide with the identifiers in any subclass (this._account
is used by some children of plugin btp)