2018-12-26 10:36:24 +01:00
|
|
|
import * as io from 'socket.io-client'
|
|
|
|
|
|
|
|
function getUserNotificationSocket (serverUrl: string, accessToken: string) {
|
|
|
|
return io(serverUrl + '/user-notifications', {
|
|
|
|
query: { accessToken }
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
2020-11-04 15:31:32 +01:00
|
|
|
function getLiveNotificationSocket (serverUrl: string) {
|
|
|
|
return io(serverUrl + '/live-videos')
|
|
|
|
}
|
|
|
|
|
2018-12-26 10:36:24 +01:00
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
|
|
|
|
export {
|
2020-11-04 15:31:32 +01:00
|
|
|
getUserNotificationSocket,
|
|
|
|
getLiveNotificationSocket
|
2018-12-26 10:36:24 +01:00
|
|
|
}
|