@@ -22,7 +22,7 @@ development version continuously deployed to
2222Until prebuilt tarballs are available, you'll need to build Element Call from
2323source. First, clone and install the package:
2424
25- ```
25+ ``` sh
2626git clone https://github.com/element-hq/element-call.git
2727cd element-call
2828yarn
@@ -33,21 +33,22 @@ If all went well, you can now find the build output under `dist` as a series of
3333static files. These can be hosted using any web server that can be configured
3434with custom routes (see below).
3535
36- You may also wish to add a configuration file (Element Call uses the domain it's
37- hosted on as a Homeserver URL by default, but you can change this in the config
38- file). This goes in ` public/config.json ` - you can use the sample as a starting
39- point:
36+ You also need to add a configuration file which goes in ` public/config.json ` -
37+ you can use the sample as a starting point:
4038
41- ```
39+ ``` sh
4240cp config/config.sample.json public/config.json
4341# edit public/config.json
4442```
4543
44+ The sample needs editing to contain the homeserver and LiveKit backend that you
45+ are using.
46+
4647Because Element Call uses client-side routing, your server must be able to route
4748any requests to non-existing paths back to ` /index.html ` . For example, in Nginx
4849you can achieve this with the ` try_files ` directive:
4950
50- ```
51+ ``` jsonc
5152server {
5253 ...
5354 location / {
@@ -57,12 +58,6 @@ server {
5758}
5859```
5960
60- By default, the app expects you to have a Matrix homeserver (such as
61- [ Synapse] ( https://element-hq.github.io/synapse/latest/setup/installation.html ) )
62- installed locally and running on port 8008. If you wish to use a homeserver on a
63- different URL or one that is hosted on a different server, you can add a config
64- file as above, and include the homeserver URL that you'd like to use.
65-
6661Element Call requires a homeserver with registration enabled without any 3pid or
6762token requirements, if you want it to be used by unregistered users.
6863Furthermore, it is not recommended to use it with an existing homeserver where
@@ -88,13 +83,13 @@ If you're using [Synapse](https://github.com/element-hq/synapse/), you'll need
8883to additionally add the following to ` homeserver.yaml ` or Element Call won't
8984work:
9085
91- ```
86+ ``` yaml
9287experimental_features :
93- # MSC3266: Room summary API. Used for knocking over federation
94- msc3266_enabled: true
95- # MSC4222 needed for syncv2 state_after. This allow clients to
96- # correctly track the state of the room.
97- msc4222_enabled: true
88+ # MSC3266: Room summary API. Used for knocking over federation
89+ msc3266_enabled : true
90+ # MSC4222 needed for syncv2 state_after. This allow clients to
91+ # correctly track the state of the room.
92+ msc4222_enabled : true
9893
9994# The maximum allowed duration by which sent events can be delayed, as
10095# per MSC4140.
@@ -152,38 +147,25 @@ discuss and coordinate translation efforts.
152147
153148# ## Frontend
154149
155- Element Call is built against
156- [ matrix-js-sdk] ( https://github.com/matrix-org/matrix-js-sdk/pull/2553 ) . To get
157- started, clone, install, and link the package:
150+ To get started clone and set up this project :
158151
159- ```
160- git clone https://github.com/matrix-org/matrix-js-sdk.git
161- cd matrix-js-sdk
162- yarn
163- yarn link
164- ```
165-
166- Next, we can set up this project:
167-
168- ```
152+ ` ` ` sh
169153git clone https://github.com/element-hq/element-call.git
170154cd element-call
171155yarn
172- yarn link matrix-js-sdk
173156` ` `
174157
175- To use it, create a local config by, e.g., `cp ./config/config.devenv.json
176- ./public/config.json` and adapt it if necessary. The ` config.devenv.json` config
177- should work with the backend development environment as outlined in the next
178- section out of box.
158+ To use it, create a local config by, e.g., `cp ./config/config.devenv.json ./public/config.json`
159+ and adapt it if necessary. The `config.devenv.json` config should work with the backend
160+ development environment as outlined in the next section out of box.
179161
180162(Be aware, that this `config.devenv.json` is exposing a deprecated fallback
181163LiveKit config key. If the homeserver advertises SFU backend via
182164` .well-known/matrix/client` this has precedence.)
183165
184166You're now ready to launch the development server :
185167
186- ```
168+ ` ` ` sh
187169yarn dev
188170` ` `
189171
@@ -192,19 +174,19 @@ yarn dev
192174A docker compose file `dev-backend-docker-compose.yml` is provided to start the
193175whole stack of components which is required for a local development environment :
194176
195- - Minimum Synapse Setup (servername: synapse.localhost)
177+ - Minimum Synapse Setup (servername : ` synapse.localhost` )
196178- LiveKit JWT Service (Note requires Federation API and hence a TLS reverse proxy)
197- - Minimum TLS reverse proxy (servername: synapse.localhost) Note certificates
179+ - Minimum TLS reverse proxy (servername : ` synapse.localhost` ) Note certificates
198180 are valid for at least 10 years from now
199181- Minimum LiveKit SFU Setup using dev defaults for config
200- - Redis db for completness
182+ - Redis db for completeness
201183
202184These use a test 'secret' published in this repository, so this must be used
203185only for local development and **_never be exposed to the public Internet._**
204186
205187Run backend components :
206188
207- ```
189+ ` ` ` sh
208190yarn backend
209191# or for podman-compose
210192# podman-compose -f dev-backend-docker-compose.yml up
@@ -221,13 +203,15 @@ To add a new translation key you can do these steps:
2212031. Add the new key entry to the code where the new key is used : ` t("some_new_key")`
2222041. Run `yarn i18n` to extract the new key and update the translation files. This
223205 will add a skeleton entry to the `locales/en/app.json` file :
206+
224207 ` ` ` jsonc
225208 {
226209 ...
227210 "some_new_key": "",
228211 ...
229212 }
230213 ` ` `
214+
2312151. Update the skeleton entry in the `locales/en/app.json` file with
232216 the English translation :
233217
0 commit comments