# groupwat.ch

> Make your own video room to watch videos remotely with all your friends

Latest version **2.2.0** (published 2019-04-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install groupwat.ch
pnpm add groupwat.ch
yarn add groupwat.ch
bun add groupwat.ch
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.2.0 |
| Published | 2019-04-10 |
| First published | 2018-09-27 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 4 |
| Unpacked size | 458.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 7 |
| Author | @hack4mer |
| Maintainers | hack4mer |
| Keywords | groupwatch, remote, video, player, group, video, streaming |

## Links

- npm: https://www.npmjs.com/package/groupwat.ch
- Repository: https://github.com/hack4mer/groupwat.ch
- Homepage: https://github.com/hack4mer/groupwat.ch#readme
- Issues: https://github.com/hack4mer/groupwat.ch/issues
- npm.io page: https://npm.io/package/groupwat.ch

## Dependencies (4)

- [jquery](https://npm.io/package/jquery.md) ^3.3.1
- [video.js](https://npm.io/package/video.js.md) ^7.1.0
- [srt-webvtt](https://npm.io/package/srt-webvtt.md) ^1.0.1
- [react-native-google-places-autocomplete](https://npm.io/package/react-native-google-places-autocomplete.md) ^1.3.9

## Alternatives

- [byte-size](https://npm.io/package/byte-size.md) — 2.1M weekly downloads
- [speed-limiter](https://npm.io/package/speed-limiter.md) — 16.0K weekly downloads
- [@powersync/node](https://npm.io/package/@powersync/node.md) — 10.9K weekly downloads
- [@ledgerhq/coin-cardano](https://npm.io/package/@ledgerhq/coin-cardano.md) — 1.0K weekly downloads
- [@jayesol/jayeson.lib.streamfinder](https://npm.io/package/@jayesol/jayeson.lib.streamfinder.md) — 1.0K weekly downloads

## Recent versions

- 2.2.0 (latest) — 2019-04-10
- 2.0.0-beta.1 (beta) — 2018-10-17
- 2.1.0 — 2019-04-09
- 2.0.4 — 2019-02-21
- 2.0.3 — 2019-02-21
- 2.0.2-beta.1 — 2019-01-18
- 2.0.1-beta.1 — 2019-01-17
- 2.0.0-beta.3 — 2019-01-14
- 2.0.0-beta.2 — 2019-01-14
- 2.0.0-beta.0 — 2018-10-16
- 1.1.1 — 2018-10-01
- 1.1.0 — 2018-10-01
- 1.0.0 — 2018-09-27

## README

# GroupWat.ch
Make your own video room to watch videos remotely with all your friends

### Demo
Here's is a demo : <https://groupwat.ch/examples/advanced.html>

### Features

- Play videos  in sync with people from anywhere on the globe
- Video call, voice call, chat room
- Support .srt and .vtt subtitles, can be added from your local disk
- Play your local video files [No downloding or streaming]
- [Video.js](https://github.com/videojs/video.js) video player, highly customizable and open-source 
- Uses WebSocket server  not WebRTC, hence easy to deploy without HTTPS
- Handy to use as a standalone in your web-browser

**Note :  current version on Groupwat.ch supports two peers (people) only, we are adding multiple peer support very soon**
## QuickStart
#### Include CSS

    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/simple-line-icons/2.4.1/css/simple-line-icons.css">
    <link href="https://unpkg.com/video.js@7.1.0/dist/video-js.css" rel="stylesheet">
    <link rel="stylesheet" href="https://unpkg.com/groupwat.ch/dist/css/styles.min.css">


#### Include JS

    <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
    <script src="https://unpkg.com/video.js@7.1.0/dist/video.js"></script>
    <script src="https://unpkg.com/groupwat.ch"></script>


#### Initialize the plugin
Replace `YOUR_CHANNEL_ID` and `YOUR_ROOM_ID` with your own unique identifiers. 

Read [WebSocket.in docs](https://www.websocket.in/docs)  to get help with choosing `YOUR_CHANNEL_ID` and `YOUR_ROOM_id`.



    <div id="video_container"></div>  
    <script type="text/javascript">

    var config = {
      socket_server:'wss://connect.websocket.in/YOUR_CHANNEL_ID?room_id=YOUR_ROOM_ID',
      container : 'video_container',
      src : 'https://vjs.zencdn.net/v/oceans.mp4',
      socket_server : "wss://YOUR_SOCKET_SERVER",
      videoCall:true
    }

    var mGWatch = new GWatch(config);
    </script>

This example code usage free WebSocket server from  [WebSocket.in](https://www.websocket.in/)  for WebRTC signaling, you may use your own WebSocket server if you wish to.
 
 Codepen : [https://codepen.io/hack4mer/full/dgVJpN](https://codepen.io/hack4mer/full/dgVJpN)
## Configuration
Following are configuration options available for the `GWatch` API

Note: This doc table might be outdated, see [GWatch.js source](https://github.com/hack4mer/groupwat.ch/blob/master/src/js/GWatch.js#L26) for updated configurations and [Event.js](https://github.com/hack4mer/groupwat.ch/blob/master/src/js/Events.js) for all supported events.

| Option                | Description                                     | Value  |
| ----------------------------- | ----------------------------------------------------------------------------- | -------------- |
| container             | ID of the div in which the GWatch UI should load                |  required |
| socket_server           | Complete URL of the socket server                       |  required |
| src                 | URL of the video file to play                         |  required, if `localSource != true`  |
| localSource             | Show a local-disk video file selector                     |  Default: false |
| videoCall                     | Enable video, voice  & chat features                                          |    Default: false |
| disableVideo                  | When true: Disables video & voice features, allows chat only                  |    Default: false |
| disableChat               | When true: Disables the chat feature, allows video & voice only         |  Default: false |
| devmode               | Devevelopment mode, informative console logs are disabled is set to false     |    Default: false |
| onSocketConnected       | Function to be fired when socket connection is succesful              |    `function(){ console.log("socket connected");` |
| onSocketError         | Function to be fired when socket connection fails                 |    `function(){ console.error("socket connection failed");}` |





License
----

MIT

---
_Source: https://npm.io/package/groupwat.ch · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
