16 lines
398 B
TypeScript
16 lines
398 B
TypeScript
import { DEFAULT_CONNECTION_CONFIG } from '../Defaults'
|
|
import type { UserFacingSocketConfig } from '../Types'
|
|
import { makeCommunitiesSocket } from './communities'
|
|
|
|
// export the last socket layer
|
|
const makeWASocket = (config: UserFacingSocketConfig) => {
|
|
const newConfig = {
|
|
...DEFAULT_CONNECTION_CONFIG,
|
|
...config
|
|
}
|
|
|
|
return makeCommunitiesSocket(newConfig)
|
|
}
|
|
|
|
export default makeWASocket
|