Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/philnash/twilio-video-svelte
A Twilio Video application built with Svelte
https://github.com/philnash/twilio-video-svelte
svelte sveltejs twilio twilio-video
Last synced: 6 days ago
JSON representation
A Twilio Video application built with Svelte
- Host: GitHub
- URL: https://github.com/philnash/twilio-video-svelte
- Owner: philnash
- License: mit
- Created: 2019-12-01T06:00:47.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2023-10-27T05:02:27.000Z (about 1 year ago)
- Last Synced: 2024-04-14T07:46:38.011Z (7 months ago)
- Topics: svelte, sveltejs, twilio, twilio-video
- Language: Svelte
- Size: 75.2 KB
- Stars: 22
- Watchers: 3
- Forks: 4
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Twilio Video built in Svelte
This is a first attempt at creating a simple video chat application using [Twilio Video](https://www.twilio.com/docs/video) and [Svelte](https://svelte.dev) as the front end framework.
![An example of the video chat. It's me waving at myself in a video chat with myself.](https://i.imgur.com/eZB4NZR.png)
## Running the project
### What you'll need
- [Node.js](https://nodejs.org) installed
- A Twilio account (you can sign up for a [free Twilio account here](https://www.twilio.com/try-twilio))### Getting started
Clone the project and change into the directory:
```bash
git clone https://github.com/philnash/twilio-video-svelte.git
cd twilio-video-svelte
```Install the dependencies:
```bash
npm install
```Copy the `.env.example` file to `.env`:
```bash
cp .env.example .env
```Create an endpoint you can request an access token from. Check out this [Twilio Function template for Video Tokens as a starting point](https://github.com/twilio-labs/function-templates/tree/master/video-token).
Once you have that running, set the URL of the token endpoint as the `TOKEN_URL` in `.env.`.
Then start [Rollup](https://rollupjs.org):
```bash
npm run dev
```Navigate to [localhost:5000](http://localhost:5000). You should see your app running.
### Building and running in production mode
To create an optimised version of the app:
```bash
npm run build
```You can run the newly built app with `npm run start` which uses [sirv](https://github.com/lukeed/sirv).