pingerchips-js 1.0.0 → 1.0.1-a
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +38 -38
- package/dist/node/pingerchips.js +10870 -0
- package/dist/node/pingerchips.js.map +1 -0
- package/dist/react-native/pingerchips.js +9 -0
- package/dist/react-native/pingerchips.js.map +1 -0
- package/dist/web/pingerchips-with-encryption.js +7009 -0
- package/dist/web/pingerchips-with-encryption.js.map +1 -0
- package/dist/web/pingerchips-with-encryption.min.js +9 -0
- package/dist/web/pingerchips-with-encryption.min.js.map +1 -0
- package/dist/web/pingerchips.js +4587 -0
- package/dist/web/pingerchips.js.map +1 -0
- package/dist/web/pingerchips.min.js +9 -0
- package/dist/web/pingerchips.min.js.map +1 -0
- package/dist/worker/pingerchips-with-encryption.worker.js +6622 -0
- package/dist/worker/pingerchips-with-encryption.worker.js.map +1 -0
- package/dist/worker/pingerchips-with-encryption.worker.min.js +9 -0
- package/dist/worker/pingerchips-with-encryption.worker.min.js.map +1 -0
- package/dist/worker/pingerchips.worker.js +4200 -0
- package/dist/worker/pingerchips.worker.js.map +1 -0
- package/dist/worker/pingerchips.worker.min.js +9 -0
- package/dist/worker/pingerchips.worker.min.js.map +1 -0
- package/package.json +4 -4
- package/react-native/index.d.ts +9 -9
- package/spec/javascripts/helpers/pusher_integration_class.ts +6 -7
- package/src/core/channels/channel.ts +3 -3
- package/src/core/channels/channels.ts +1 -1
- package/src/core/channels/encrypted_channel.ts +3 -3
- package/src/core/channels/presence_channel.ts +1 -1
- package/src/core/config.ts +10 -10
- package/src/core/defaults.ts +5 -5
- package/src/core/logger.ts +1 -1
- package/src/core/pingerchips-with-encryption.js +1 -0
- package/src/core/{pusher-with-encryption.ts → pingerchips-with-encryption.ts} +1 -1
- package/src/core/{pusher.js → pingerchips.js} +1 -1
- package/src/core/user.ts +3 -3
- package/src/core/utils/factory.ts +3 -3
- package/src/core/watchlist.ts +1 -1
- package/src/runtimes/interface.ts +1 -1
- package/types/spec/javascripts/helpers/pusher_integration_class.d.ts +1 -1
- package/types/src/core/channels/channel.d.ts +1 -1
- package/types/src/core/channels/channels.d.ts +1 -1
- package/types/src/core/channels/encrypted_channel.d.ts +1 -1
- package/types/src/core/channels/presence_channel.d.ts +1 -1
- package/types/src/core/config.d.ts +2 -2
- package/types/src/core/{pusher-with-encryption.d.ts → pingerchips-with-encryption.d.ts} +1 -1
- package/types/src/core/user.d.ts +1 -1
- package/types/src/core/utils/factory.d.ts +1 -1
- package/types/src/core/watchlist.d.ts +1 -1
- package/types/src/runtimes/interface.d.ts +1 -1
- package/webpack/config.node.js +3 -3
- package/webpack/config.react-native.js +3 -3
- package/webpack/config.shared.js +2 -2
- package/webpack/config.web.js +7 -7
- package/webpack/config.worker.js +7 -7
- package/with-encryption/index.d.ts +9 -9
- package/worker/index.d.ts +9 -9
- package/worker/with-encryption/index.d.ts +9 -9
- package/src/core/pusher-with-encryption.js +0 -1
- /package/src/core/{pusher-licence.js → pingerchips-licence.js} +0 -0
- /package/src/core/{pusher.ts → pingerchips.ts} +0 -0
- /package/types/src/core/{pusher.d.ts → pingerchips.d.ts} +0 -0
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pingerchips-js",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1a",
|
|
4
4
|
"description": "Pingerchips Channels JavaScript library for browsers, React Native, NodeJS and web workers",
|
|
5
|
-
"main": "dist/node/
|
|
6
|
-
"browser": "dist/web/
|
|
7
|
-
"react-native": "dist/react-native/
|
|
5
|
+
"main": "dist/node/pingerchips.js",
|
|
6
|
+
"browser": "dist/web/pingerchips.js",
|
|
7
|
+
"react-native": "dist/react-native/pingerchips.js",
|
|
8
8
|
"scripts": {
|
|
9
9
|
"test": "echo \"Error: no test specified\" && exit 1",
|
|
10
10
|
"format": "prettier --config .prettierrc --write 'src/**/*.ts' 'webpack/**/*.js'",
|
package/react-native/index.d.ts
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
export {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
ChannelAuthorizerGenerator,
|
|
3
|
+
DeprecatedAuthOptions
|
|
4
4
|
} from '../types/src/core/auth/deprecated_channel_authorizer';
|
|
5
5
|
export {
|
|
6
|
-
|
|
7
|
-
ChannelAuthorizationOptions,
|
|
6
|
+
ChannelAuthorizationCallback,
|
|
8
7
|
ChannelAuthorizationHandler,
|
|
8
|
+
ChannelAuthorizationOptions,
|
|
9
|
+
UserAuthenticationCallback,
|
|
9
10
|
UserAuthenticationHandler,
|
|
10
|
-
|
|
11
|
-
UserAuthenticationCallback
|
|
11
|
+
UserAuthenticationOptions
|
|
12
12
|
} from '../types/src/core/auth/options';
|
|
13
13
|
export { Options } from '../types/src/core/options';
|
|
14
14
|
|
|
15
15
|
export { default as Channel } from '../types/src/core/channels/channel';
|
|
16
|
-
export { default as PresenceChannel } from '../types/src/core/channels/presence_channel';
|
|
17
16
|
export { default as Members } from '../types/src/core/channels/members';
|
|
18
|
-
export { default as
|
|
17
|
+
export { default as PresenceChannel } from '../types/src/core/channels/presence_channel';
|
|
19
18
|
export { default as ConnectionManager } from '../types/src/core/connection/connection_manager';
|
|
19
|
+
export { default as Runtime } from '../types/src/runtimes/interface';
|
|
20
20
|
|
|
21
|
-
export { default } from '../types/src/core/
|
|
21
|
+
export { default } from '../types/src/core/pingerchips';
|
|
22
22
|
|
|
23
23
|
// The following types are provided for backward compatability
|
|
24
24
|
export {
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
import Pingerchips from '../../../src/core/
|
|
1
|
+
import Pingerchips from '../../../src/core/pingerchips';
|
|
2
2
|
import { ScriptReceiverFactory } from '../../../src/runtimes/web/dom/script_receiver_factory';
|
|
3
3
|
|
|
4
4
|
export default class PusherIntegration extends Pingerchips {
|
|
5
|
-
|
|
6
|
-
static Integration : any = {
|
|
5
|
+
static Integration: any = {
|
|
7
6
|
ScriptReceivers: new ScriptReceiverFactory(
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
)
|
|
11
|
-
|
|
7
|
+
'_pusher_integration_script_receivers',
|
|
8
|
+
'Pusher.Integration.ScriptReceivers'
|
|
9
|
+
)
|
|
10
|
+
};
|
|
12
11
|
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
ChannelAuthorizationCallback,
|
|
3
|
+
ChannelAuthorizationData
|
|
4
4
|
} from '../auth/options';
|
|
5
5
|
import { PusherEvent } from '../connection/protocol/message-types';
|
|
6
6
|
import * as Errors from '../errors';
|
|
7
7
|
import { HTTPAuthError } from '../errors';
|
|
8
8
|
import { default as EventsDispatcher } from '../events/dispatcher';
|
|
9
9
|
import Logger from '../logger';
|
|
10
|
-
import Pingerchips from '../
|
|
10
|
+
import Pingerchips from '../pingerchips';
|
|
11
11
|
import UrlStore from '../utils/url_store';
|
|
12
12
|
import Metadata from './metadata';
|
|
13
13
|
|
|
@@ -2,13 +2,13 @@ import { decode as decodeBase64 } from '@stablelib/base64';
|
|
|
2
2
|
import { decode as encodeUTF8 } from '@stablelib/utf8';
|
|
3
3
|
import * as nacl from 'tweetnacl';
|
|
4
4
|
import {
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
ChannelAuthorizationCallback,
|
|
6
|
+
ChannelAuthorizationData
|
|
7
7
|
} from '../auth/options';
|
|
8
8
|
import { PusherEvent } from '../connection/protocol/message-types';
|
|
9
9
|
import * as Errors from '../errors';
|
|
10
10
|
import Logger from '../logger';
|
|
11
|
-
import Pingerchips from '../
|
|
11
|
+
import Pingerchips from '../pingerchips';
|
|
12
12
|
import PrivateChannel from './private_channel';
|
|
13
13
|
|
|
14
14
|
/** Extends private channels to provide encrypted channel interface.
|
|
@@ -2,7 +2,7 @@ import UrlStore from 'core/utils/url_store';
|
|
|
2
2
|
import { ChannelAuthorizationData } from '../auth/options';
|
|
3
3
|
import { PusherEvent } from '../connection/protocol/message-types';
|
|
4
4
|
import Logger from '../logger';
|
|
5
|
-
import Pingerchips from '../
|
|
5
|
+
import Pingerchips from '../pingerchips';
|
|
6
6
|
import Members from './members';
|
|
7
7
|
import Metadata from './metadata';
|
|
8
8
|
import PrivateChannel from './private_channel';
|
package/src/core/config.ts
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
1
|
+
import Runtime from 'runtime';
|
|
2
|
+
import * as nacl from 'tweetnacl';
|
|
3
|
+
import ChannelAuthorizer from './auth/channel_authorizer';
|
|
4
|
+
import { ChannelAuthorizerProxy } from './auth/deprecated_channel_authorizer';
|
|
3
5
|
import {
|
|
4
6
|
ChannelAuthorizationHandler,
|
|
5
|
-
|
|
6
|
-
|
|
7
|
+
ChannelAuthorizationOptions,
|
|
8
|
+
UserAuthenticationHandler
|
|
7
9
|
} from './auth/options';
|
|
8
10
|
import UserAuthenticator from './auth/user_authenticator';
|
|
9
|
-
import
|
|
10
|
-
import {
|
|
11
|
-
import Runtime from 'runtime';
|
|
12
|
-
import * as nacl from 'tweetnacl';
|
|
11
|
+
import Defaults from './defaults';
|
|
12
|
+
import { Options } from './options';
|
|
13
13
|
|
|
14
14
|
export type AuthTransport = 'ajax' | 'jsonp';
|
|
15
15
|
export type Transport =
|
|
@@ -93,7 +93,7 @@ function getHttpHost(opts: Options): string {
|
|
|
93
93
|
return opts.httpHost;
|
|
94
94
|
}
|
|
95
95
|
if (opts.cluster) {
|
|
96
|
-
return `sockjs
|
|
96
|
+
return `sockjs.pingerchips.com`;
|
|
97
97
|
}
|
|
98
98
|
return Defaults.httpHost;
|
|
99
99
|
}
|
|
@@ -106,7 +106,7 @@ function getWebsocketHost(opts: Options): string {
|
|
|
106
106
|
}
|
|
107
107
|
|
|
108
108
|
function getWebsocketHostFromCluster(cluster: string): string {
|
|
109
|
-
return `ws
|
|
109
|
+
return `ws.pingerchips.com`;
|
|
110
110
|
}
|
|
111
111
|
|
|
112
112
|
function shouldUseTLS(opts: Options): boolean {
|
package/src/core/defaults.ts
CHANGED
|
@@ -32,7 +32,7 @@ var Defaults: DefaultConfig = {
|
|
|
32
32
|
VERSION: VERSION,
|
|
33
33
|
PROTOCOL: 7,
|
|
34
34
|
|
|
35
|
-
wsPort:
|
|
35
|
+
wsPort: 6001,
|
|
36
36
|
wssPort: 443,
|
|
37
37
|
wsPath: '',
|
|
38
38
|
// DEPRECATED: SockJS fallback parameters
|
|
@@ -41,19 +41,19 @@ var Defaults: DefaultConfig = {
|
|
|
41
41
|
httpsPort: 443,
|
|
42
42
|
httpPath: '/pusher',
|
|
43
43
|
// DEPRECATED: Stats
|
|
44
|
-
stats_host: 'stats.
|
|
44
|
+
stats_host: 'stats.pingerchips.com',
|
|
45
45
|
// DEPRECATED: Other settings
|
|
46
|
-
authEndpoint: '/
|
|
46
|
+
authEndpoint: '/pingerchips/auth',
|
|
47
47
|
authTransport: 'ajax',
|
|
48
48
|
activityTimeout: 120000,
|
|
49
49
|
pongTimeout: 30000,
|
|
50
50
|
unavailableTimeout: 10000,
|
|
51
51
|
userAuthentication: {
|
|
52
|
-
endpoint: '/
|
|
52
|
+
endpoint: '/pingerchips/user-auth',
|
|
53
53
|
transport: 'ajax'
|
|
54
54
|
},
|
|
55
55
|
channelAuthorization: {
|
|
56
|
-
endpoint: '/
|
|
56
|
+
endpoint: '/pingerchips/auth',
|
|
57
57
|
transport: 'ajax'
|
|
58
58
|
},
|
|
59
59
|
|
package/src/core/logger.ts
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
module.exports = require('./pingerchips-with-encryption').default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as nacl from 'tweetnacl';
|
|
2
2
|
import { Options, validateOptions } from './options';
|
|
3
|
-
import Pingerchips from './
|
|
3
|
+
import Pingerchips from './pingerchips';
|
|
4
4
|
|
|
5
5
|
export default class PusherWithEncryption extends Pingerchips {
|
|
6
6
|
constructor(app_key: string, options: Options) {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// required so we don't have to do require('pusher').default etc.
|
|
2
|
-
module.exports = require('./
|
|
2
|
+
module.exports = require('./pingerchips').default;
|
package/src/core/user.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
UserAuthenticationCallback,
|
|
3
|
+
UserAuthenticationData
|
|
4
4
|
} from './auth/options';
|
|
5
5
|
import Channel from './channels/channel';
|
|
6
6
|
import EventsDispatcher from './events/dispatcher';
|
|
7
7
|
import Logger from './logger';
|
|
8
|
-
import Pingerchips from './
|
|
8
|
+
import Pingerchips from './pingerchips';
|
|
9
9
|
import flatPromise from './utils/flat_promise';
|
|
10
10
|
import WatchlistFacade from './watchlist';
|
|
11
11
|
|
|
@@ -13,11 +13,11 @@ import PresenceChannel from '../channels/presence_channel';
|
|
|
13
13
|
import PrivateChannel from '../channels/private_channel';
|
|
14
14
|
import ConnectionManager from '../connection/connection_manager';
|
|
15
15
|
import ConnectionManagerOptions from '../connection/connection_manager_options';
|
|
16
|
-
import Pingerchips from '../
|
|
16
|
+
import Pingerchips from '../pingerchips';
|
|
17
17
|
import Timeline from '../timeline/timeline';
|
|
18
18
|
import {
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
default as TimelineSender,
|
|
20
|
+
TimelineSenderOptions
|
|
21
21
|
} from '../timeline/timeline_sender';
|
|
22
22
|
|
|
23
23
|
var Factory = {
|
package/src/core/watchlist.ts
CHANGED
|
@@ -3,7 +3,7 @@ import { Config } from '../core/config';
|
|
|
3
3
|
import Ajax from '../core/http/ajax';
|
|
4
4
|
import HTTPFactory from '../core/http/http_factory';
|
|
5
5
|
import HTTPRequest from '../core/http/http_request';
|
|
6
|
-
import Pingerchips from '../core/
|
|
6
|
+
import Pingerchips from '../core/pingerchips';
|
|
7
7
|
import Reachability from '../core/reachability';
|
|
8
8
|
import Socket from '../core/socket';
|
|
9
9
|
import Strategy from '../core/strategies/strategy';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ChannelAuthorizationCallback } from '../auth/options';
|
|
2
2
|
import { PusherEvent } from '../connection/protocol/message-types';
|
|
3
3
|
import { default as EventsDispatcher } from '../events/dispatcher';
|
|
4
|
-
import Pingerchips from '../
|
|
4
|
+
import Pingerchips from '../pingerchips';
|
|
5
5
|
export default class Channel extends EventsDispatcher {
|
|
6
6
|
name: string;
|
|
7
7
|
pusher: Pingerchips;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as nacl from 'tweetnacl';
|
|
2
2
|
import { ChannelAuthorizationCallback } from '../auth/options';
|
|
3
3
|
import { PusherEvent } from '../connection/protocol/message-types';
|
|
4
|
-
import Pingerchips from '../
|
|
4
|
+
import Pingerchips from '../pingerchips';
|
|
5
5
|
import PrivateChannel from './private_channel';
|
|
6
6
|
export default class EncryptedChannel extends PrivateChannel {
|
|
7
7
|
key: Uint8Array;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PusherEvent } from '../connection/protocol/message-types';
|
|
2
|
-
import Pingerchips from '../
|
|
2
|
+
import Pingerchips from '../pingerchips';
|
|
3
3
|
import Members from './members';
|
|
4
4
|
import PrivateChannel from './private_channel';
|
|
5
5
|
export default class PresenceChannel extends PrivateChannel {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Options } from './options';
|
|
2
|
-
import { ChannelAuthorizationHandler, UserAuthenticationHandler } from './auth/options';
|
|
3
1
|
import * as nacl from 'tweetnacl';
|
|
2
|
+
import { ChannelAuthorizationHandler, UserAuthenticationHandler } from './auth/options';
|
|
3
|
+
import { Options } from './options';
|
|
4
4
|
export type AuthTransport = 'ajax' | 'jsonp';
|
|
5
5
|
export type Transport = 'ws' | 'wss' | 'xhr_streaming' | 'xhr_polling' | 'sockjs';
|
|
6
6
|
export interface Config {
|
package/types/src/core/user.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import Channel from './channels/channel';
|
|
2
2
|
import EventsDispatcher from './events/dispatcher';
|
|
3
|
-
import Pingerchips from './
|
|
3
|
+
import Pingerchips from './pingerchips';
|
|
4
4
|
import WatchlistFacade from './watchlist';
|
|
5
5
|
export default class UserFacade extends EventsDispatcher {
|
|
6
6
|
pusher: Pingerchips;
|
|
@@ -12,7 +12,7 @@ import PresenceChannel from '../channels/presence_channel';
|
|
|
12
12
|
import PrivateChannel from '../channels/private_channel';
|
|
13
13
|
import ConnectionManager from '../connection/connection_manager';
|
|
14
14
|
import ConnectionManagerOptions from '../connection/connection_manager_options';
|
|
15
|
-
import Pingerchips from '../
|
|
15
|
+
import Pingerchips from '../pingerchips';
|
|
16
16
|
import Timeline from '../timeline/timeline';
|
|
17
17
|
import { default as TimelineSender, TimelineSenderOptions } from '../timeline/timeline_sender';
|
|
18
18
|
declare var Factory: {
|
|
@@ -3,7 +3,7 @@ import { Config } from '../core/config';
|
|
|
3
3
|
import Ajax from '../core/http/ajax';
|
|
4
4
|
import HTTPFactory from '../core/http/http_factory';
|
|
5
5
|
import HTTPRequest from '../core/http/http_request';
|
|
6
|
-
import Pingerchips from '../core/
|
|
6
|
+
import Pingerchips from '../core/pingerchips';
|
|
7
7
|
import Reachability from '../core/reachability';
|
|
8
8
|
import Socket from '../core/socket';
|
|
9
9
|
import Strategy from '../core/strategies/strategy';
|
package/webpack/config.node.js
CHANGED
|
@@ -5,13 +5,13 @@ var webpack = require('webpack');
|
|
|
5
5
|
|
|
6
6
|
module.exports = merge({}, configShared, {
|
|
7
7
|
entry: {
|
|
8
|
-
|
|
8
|
+
pingerchips: './src/core/pingerchips-with-encryption.js'
|
|
9
9
|
},
|
|
10
10
|
output: {
|
|
11
|
-
library: '
|
|
11
|
+
library: 'Pingerchips',
|
|
12
12
|
libraryTarget: 'commonjs2',
|
|
13
13
|
path: path.join(__dirname, '../dist/node'),
|
|
14
|
-
filename: '
|
|
14
|
+
filename: 'pingerchips.js'
|
|
15
15
|
},
|
|
16
16
|
target: 'node',
|
|
17
17
|
resolve: {
|
|
@@ -9,13 +9,13 @@ var buffer = require('buffer');
|
|
|
9
9
|
|
|
10
10
|
module.exports = merge({}, configShared, {
|
|
11
11
|
entry: {
|
|
12
|
-
|
|
12
|
+
pingerchips: './src/core/pingerchips-with-encryption.js'
|
|
13
13
|
},
|
|
14
14
|
output: {
|
|
15
|
-
library: '
|
|
15
|
+
library: 'Pingerchips',
|
|
16
16
|
libraryTarget: 'commonjs2',
|
|
17
17
|
path: path.join(__dirname, '../dist/react-native'),
|
|
18
|
-
filename: '
|
|
18
|
+
filename: 'pingerchips.js'
|
|
19
19
|
},
|
|
20
20
|
externals: {
|
|
21
21
|
// our Reachability implementation needs to reference @react-native-community/netinfo.
|
package/webpack/config.shared.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
var webpack = require('webpack');
|
|
4
4
|
var fs = require('fs');
|
|
5
5
|
var Config = require('./hosting_config');
|
|
6
|
-
var banner = fs.readFileSync('./src/core/
|
|
6
|
+
var banner = fs.readFileSync('./src/core/pingerchips-licence.js', 'utf8');
|
|
7
7
|
banner = banner.replace('<VERSION>', Config.version);
|
|
8
8
|
|
|
9
9
|
var minimize = process.env.MINIMIZE === 'false' ? false : true;
|
|
@@ -14,7 +14,7 @@ module.exports = {
|
|
|
14
14
|
minimize: minimize
|
|
15
15
|
},
|
|
16
16
|
entry: {
|
|
17
|
-
|
|
17
|
+
pingerchips: './src/core/pusher.js'
|
|
18
18
|
},
|
|
19
19
|
devtool: 'source-map',
|
|
20
20
|
resolve: {
|
package/webpack/config.web.js
CHANGED
|
@@ -5,21 +5,21 @@ const { merge } = require('webpack-merge');
|
|
|
5
5
|
var configShared = require('./config.shared');
|
|
6
6
|
|
|
7
7
|
var filename = configShared.optimization.minimize
|
|
8
|
-
? '
|
|
9
|
-
: '
|
|
8
|
+
? 'pingerchips.min.js'
|
|
9
|
+
: 'pingerchips.js';
|
|
10
10
|
|
|
11
|
-
var entry = './src/core/
|
|
11
|
+
var entry = './src/core/pingerchips.js';
|
|
12
12
|
if (process.env.INCLUDE_TWEETNACL === 'true') {
|
|
13
|
-
entry = './src/core/
|
|
14
|
-
filename = filename.replace('
|
|
13
|
+
entry = './src/core/pingerchips-with-encryption.js';
|
|
14
|
+
filename = filename.replace('pingerchips', 'pingerchips-with-encryption');
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
module.exports = merge({}, configShared, {
|
|
18
18
|
entry: {
|
|
19
|
-
|
|
19
|
+
pingerchips: entry
|
|
20
20
|
},
|
|
21
21
|
output: {
|
|
22
|
-
library: '
|
|
22
|
+
library: 'Pingerchips',
|
|
23
23
|
path: path.join(__dirname, '../dist/web'),
|
|
24
24
|
filename: filename,
|
|
25
25
|
libraryTarget: 'umd'
|
package/webpack/config.worker.js
CHANGED
|
@@ -7,21 +7,21 @@ var webpack = require('webpack');
|
|
|
7
7
|
var configShared = require('./config.shared');
|
|
8
8
|
|
|
9
9
|
var filename = configShared.optimization.minimize
|
|
10
|
-
? '
|
|
11
|
-
: '
|
|
10
|
+
? 'pingerchips.worker.min.js'
|
|
11
|
+
: 'pingerchips.worker.js';
|
|
12
12
|
|
|
13
|
-
var entry = './src/core/
|
|
13
|
+
var entry = './src/core/pingerchips.js';
|
|
14
14
|
if (process.env.INCLUDE_TWEETNACL === 'true') {
|
|
15
|
-
entry = './src/core/
|
|
16
|
-
filename = filename.replace('
|
|
15
|
+
entry = './src/core/pingerchips-with-encryption.js';
|
|
16
|
+
filename = filename.replace('pingerchips', 'pingerchips-with-encryption');
|
|
17
17
|
}
|
|
18
18
|
|
|
19
19
|
var config = merge(configShared, {
|
|
20
20
|
entry: {
|
|
21
|
-
|
|
21
|
+
pingerchips: entry
|
|
22
22
|
},
|
|
23
23
|
output: {
|
|
24
|
-
library: '
|
|
24
|
+
library: 'Pingerchips',
|
|
25
25
|
path: path.join(__dirname, '../dist/worker'),
|
|
26
26
|
filename: filename,
|
|
27
27
|
libraryTarget: 'umd',
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
export {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
ChannelAuthorizerGenerator,
|
|
3
|
+
DeprecatedAuthOptions
|
|
4
4
|
} from '../types/src/core/auth/deprecated_channel_authorizer';
|
|
5
5
|
export {
|
|
6
|
-
|
|
7
|
-
UserAuthenticationOptions,
|
|
6
|
+
ChannelAuthorizationCallback,
|
|
8
7
|
ChannelAuthorizationHandler,
|
|
8
|
+
ChannelAuthorizationOptions,
|
|
9
|
+
UserAuthenticationCallback,
|
|
9
10
|
UserAuthenticationHandler,
|
|
10
|
-
|
|
11
|
-
UserAuthenticationCallback
|
|
11
|
+
UserAuthenticationOptions
|
|
12
12
|
} from '../types/src/core/auth/options';
|
|
13
13
|
export { Options } from '../types/src/core/options';
|
|
14
14
|
|
|
15
15
|
export { default as Channel } from '../types/src/core/channels/channel';
|
|
16
|
-
export { default as PresenceChannel } from '../types/src/core/channels/presence_channel';
|
|
17
16
|
export { default as Members } from '../types/src/core/channels/members';
|
|
18
|
-
export { default as
|
|
17
|
+
export { default as PresenceChannel } from '../types/src/core/channels/presence_channel';
|
|
19
18
|
export { default as ConnectionManager } from '../types/src/core/connection/connection_manager';
|
|
19
|
+
export { default as Runtime } from '../types/src/runtimes/interface';
|
|
20
20
|
|
|
21
|
-
export { default } from '../types/src/core/
|
|
21
|
+
export { default } from '../types/src/core/pingerchips';
|
|
22
22
|
|
|
23
23
|
// The following types are provided for backward compatability
|
|
24
24
|
export {
|
package/worker/index.d.ts
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
export {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
ChannelAuthorizerGenerator,
|
|
3
|
+
DeprecatedAuthOptions
|
|
4
4
|
} from '../types/src/core/auth/deprecated_channel_authorizer';
|
|
5
5
|
export {
|
|
6
|
-
|
|
7
|
-
UserAuthenticationOptions,
|
|
6
|
+
ChannelAuthorizationCallback,
|
|
8
7
|
ChannelAuthorizationHandler,
|
|
8
|
+
ChannelAuthorizationOptions,
|
|
9
|
+
UserAuthenticationCallback,
|
|
9
10
|
UserAuthenticationHandler,
|
|
10
|
-
|
|
11
|
-
UserAuthenticationCallback
|
|
11
|
+
UserAuthenticationOptions
|
|
12
12
|
} from '../types/src/core/auth/options';
|
|
13
13
|
export { Options } from '../types/src/core/options';
|
|
14
14
|
|
|
15
15
|
export { default as Channel } from '../types/src/core/channels/channel';
|
|
16
|
-
export { default as PresenceChannel } from '../types/src/core/channels/presence_channel';
|
|
17
16
|
export { default as Members } from '../types/src/core/channels/members';
|
|
18
|
-
export { default as
|
|
17
|
+
export { default as PresenceChannel } from '../types/src/core/channels/presence_channel';
|
|
19
18
|
export { default as ConnectionManager } from '../types/src/core/connection/connection_manager';
|
|
19
|
+
export { default as Runtime } from '../types/src/runtimes/interface';
|
|
20
20
|
|
|
21
|
-
export { default } from '../types/src/core/
|
|
21
|
+
export { default } from '../types/src/core/pingerchips';
|
|
22
22
|
|
|
23
23
|
// The following types are provided for backward compatability
|
|
24
24
|
export {
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
export {
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
ChannelAuthorizerGenerator,
|
|
3
|
+
DeprecatedAuthOptions
|
|
4
4
|
} from '../../types/src/core/auth/deprecated_channel_authorizer';
|
|
5
5
|
export {
|
|
6
|
-
|
|
7
|
-
UserAuthenticationOptions,
|
|
6
|
+
ChannelAuthorizationCallback,
|
|
8
7
|
ChannelAuthorizationHandler,
|
|
8
|
+
ChannelAuthorizationOptions,
|
|
9
|
+
UserAuthenticationCallback,
|
|
9
10
|
UserAuthenticationHandler,
|
|
10
|
-
|
|
11
|
-
UserAuthenticationCallback
|
|
11
|
+
UserAuthenticationOptions
|
|
12
12
|
} from '../../types/src/core/auth/options';
|
|
13
13
|
export { Options } from '../../types/src/core/options';
|
|
14
14
|
|
|
15
15
|
export { default as Channel } from '../../types/src/core/channels/channel';
|
|
16
|
-
export { default as PresenceChannel } from '../../types/src/core/channels/presence_channel';
|
|
17
16
|
export { default as Members } from '../../types/src/core/channels/members';
|
|
18
|
-
export { default as
|
|
17
|
+
export { default as PresenceChannel } from '../../types/src/core/channels/presence_channel';
|
|
19
18
|
export { default as ConnectionManager } from '../../types/src/core/connection/connection_manager';
|
|
19
|
+
export { default as Runtime } from '../../types/src/runtimes/interface';
|
|
20
20
|
|
|
21
|
-
export { default } from '../../types/src/core/
|
|
21
|
+
export { default } from '../../types/src/core/pingerchips';
|
|
22
22
|
|
|
23
23
|
// The following types are provided for backward compatability
|
|
24
24
|
export {
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require('./pusher-with-encryption').default;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|