Skip to content

Commit 81dad06

Browse files
committed
Initial commit
1 parent 8342d59 commit 81dad06

File tree

2,440 files changed

+264284
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,440 files changed

+264284
-0
lines changed

.gitignore

+93
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
*.swp
2+
.*.tmp
3+
deploy-local.sh
4+
libs/
5+
all.css
6+
*css.map
7+
.remote-sync.json
8+
.sync-config.cson
9+
10+
# CocoaPods
11+
Pods/
12+
13+
# The following are automatically generated by the react-native command line
14+
# utility (either with the init or upgrade option which pull in the latest
15+
# template files recommended by Facebook for React Native).
16+
17+
# OSX
18+
#
19+
.DS_Store
20+
21+
# Xcode
22+
#
23+
build/
24+
*.pbxuser
25+
!default.pbxuser
26+
*.mode1v3
27+
!default.mode1v3
28+
*.mode2v3
29+
!default.mode2v3
30+
*.perspectivev3
31+
!default.perspectivev3
32+
xcuserdata
33+
*.xccheckout
34+
*.moved-aside
35+
DerivedData
36+
*.hmap
37+
*.ipa
38+
*.dSYM.zip
39+
*.xcuserstate
40+
project.xcworkspace
41+
42+
# Android/IntelliJ
43+
#
44+
build/
45+
.idea
46+
.gradle
47+
local.properties
48+
*.iml
49+
50+
# node.js
51+
#
52+
node_modules/
53+
npm-debug.log
54+
yarn-error.log
55+
56+
# BUCK
57+
#
58+
buck-out/
59+
\.buckd/
60+
*.keystore
61+
62+
# fastlane
63+
#
64+
*/fastlane/report.xml
65+
*/fastlane/Preview.html
66+
67+
# Build artifacts
68+
*.jsbundle
69+
*.framework
70+
android/app/debug
71+
android/app/release
72+
ios/sdk/out
73+
74+
# precommit-hook
75+
.jshintignore
76+
.jshintrc
77+
78+
# VSCode files
79+
android/.project
80+
android/.settings/org.eclipse.buildship.core.prefs
81+
82+
# Secrets
83+
android/app/dropbox.key
84+
android/app/google-services.json
85+
ios/app/dropbox.key
86+
ios/app/GoogleService-Info.plist
87+
88+
.vscode
89+
90+
# TWA
91+
twa/*.apk
92+
twa/*.aab
93+
twa/assetlinks.json

CONTRIBUTING.md

+171
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,171 @@
1+
# How to contribute
2+
We would love to have your help. Before you start working however, please read
3+
and follow this short guide.
4+
5+
# Reporting Issues
6+
Provide as much information as possible. Mention the version of Jitsi Meet,
7+
Jicofo and JVB you are using, and explain (as detailed as you can) how the
8+
problem can be reproduced.
9+
10+
# Code contributions
11+
Found a bug and know how to fix it? Great! Please read on.
12+
13+
## Contributor License Agreement
14+
While the Jitsi projects are released under the
15+
[Apache License 2.0](https://github.com/jitsi/jitsi-meet/blob/master/LICENSE), the copyright
16+
holder and principal creator is [8x8](https://www.8x8.com/). To
17+
ensure that we can continue making these projects available under an Open Source license,
18+
we need you to sign our Apache-based contributor
19+
license agreement as either a [corporation](https://jitsi.org/ccla) or an
20+
[individual](https://jitsi.org/icla). If you cannot accept the terms laid out
21+
in the agreement, unfortunately, we cannot accept your contribution.
22+
23+
## Creating Pull Requests
24+
- Make sure your code passes the linter rules beforehand. The linter is executed
25+
automatically when committing code.
26+
- Perform **one** logical change per pull request.
27+
- Maintain a clean list of commits, squash them if necessary.
28+
- Rebase your topic branch on top of the master branch before creating the pull
29+
request.
30+
31+
## Coding style
32+
33+
### Comments
34+
35+
* Comments documenting the source code are required.
36+
37+
* Comments from which documentation is automatically generated are **not**
38+
subject to case-by-case decisions. Such comments are used, for example, on
39+
types and their members. Examples of tools which automatically generate
40+
documentation from such comments include JSDoc, Javadoc, Doxygen.
41+
42+
* Comments which are not automatically processed are strongly encouraged. They
43+
are subject to case-by-case decisions. Such comments are often observed in
44+
function bodies.
45+
46+
* Comments should be formatted as proper English sentences. Such formatting pays
47+
attention to, for example, capitalization and punctuation.
48+
49+
### Duplication
50+
51+
* Don't copy-paste source code. Reuse it.
52+
53+
### Formatting
54+
55+
* Line length is limited to 120 characters.
56+
57+
* Sort by alphabetical order in order to make the addition of new entities as
58+
easy as looking a word up in a dictionary. Otherwise, one risks duplicate
59+
entries (with conflicting values in the cases of key-value pairs). For
60+
example:
61+
62+
* Within an `import` of multiple names from a module, sort the names in
63+
alphabetical order. (Of course, the default name stays first as required by
64+
the `import` syntax.)
65+
66+
````javascript
67+
import {
68+
DOMINANT_SPEAKER_CHANGED,
69+
JITSI_CLIENT_CONNECTED,
70+
JITSI_CLIENT_CREATED,
71+
JITSI_CLIENT_DISCONNECTED,
72+
JITSI_CLIENT_ERROR,
73+
JITSI_CONFERENCE_JOINED,
74+
MODERATOR_CHANGED,
75+
PEER_JOINED,
76+
PEER_LEFT,
77+
RTC_ERROR
78+
} from './actionTypes';
79+
````
80+
81+
* Within a group of imports (e.g. groups of imports delimited by an empty line
82+
may be: third-party modules, then project modules, and eventually the
83+
private files of a module), sort the module names in alphabetical order.
84+
85+
````javascript
86+
import React, { Component } from 'react';
87+
import { connect } from 'react-redux';
88+
````
89+
90+
### Indentation
91+
92+
* Align `switch` and `case`/`default`. Don't indent the `case`/`default` more
93+
than its `switch`.
94+
95+
````javascript
96+
switch (i) {
97+
case 0:
98+
...
99+
break;
100+
default:
101+
...
102+
}
103+
````
104+
105+
### Naming
106+
107+
* An abstraction should have one name within the project and across multiple
108+
projects. For example:
109+
110+
* The instance of lib-jitsi-meet's `JitsiConnection` type should be named
111+
`connection` or `jitsiConnection` in jitsi-meet, not `client`.
112+
113+
* The class `ReducerRegistry` should be defined in ReducerRegistry.js and its
114+
imports in other files should use the same name. Don't define the class
115+
`Registry` in ReducerRegistry.js and then import it as `Reducers` in other
116+
files.
117+
118+
* The names of global constants (including ES6 module-global constants) should
119+
be written in uppercase with underscores to separate words. For example,
120+
`BACKGROUND_COLOR`.
121+
122+
* The underscore character at the beginning of a name signals that the
123+
respective variable, function, property is non-public i.e. private, protected,
124+
or internal. In contrast, the lack of an underscore at the beginning of a name
125+
signals public API.
126+
127+
### Feature layout
128+
129+
When adding a new feature, this would be the usual layout.
130+
131+
```
132+
react/features/sample/
133+
├── actionTypes.js
134+
├── actions.js
135+
├── components
136+
│   ├── AnotherComponent.js
137+
│   ├── OneComponent.js
138+
│   └── index.js
139+
├── middleware.js
140+
└── reducer.js
141+
```
142+
143+
The middleware must be imported in `react/features/app/` specifically
144+
in `middlewares.any`, `middlewares.native.js` or `middlewares.web.js` where appropriate.
145+
Likewise for the reducer.
146+
147+
An `index.js` file must not be provided for exporting actions, action types and
148+
component. Features / files requiring those must import them explicitly.
149+
150+
This has not always been the case and the entire codebase hasn't been migrated to
151+
this model but new features should follow this new layout.
152+
153+
When working on an old feature, adding the necessary changes to migrate to the new
154+
model is encouraged.
155+
156+
157+
### Avoiding bundle bloat
158+
159+
When adding a new feature it's possible that it triggers a build failure due to the increased bundle size. We have safeguards inplace to avoid bundles growing disproportionatelly. While there are legit reasons for increasing the limits, please analyze the bundle first to make sure no unintended dependencies have been included, causing the increase in size.
160+
161+
First, make a production build with bundle-analysis enabled:
162+
163+
```
164+
npx webpack -p --analyze-bundle
165+
```
166+
167+
Then open the interactive bundle analyzer tool:
168+
169+
```
170+
npx webpack-bundle-analyzer build/app-stats.json
171+
```

Makefile

+110
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
BUILD_DIR = build
2+
CLEANCSS = ./node_modules/.bin/cleancss
3+
DEPLOY_DIR = libs
4+
LIBJITSIMEET_DIR = node_modules/lib-jitsi-meet/
5+
LIBFLAC_DIR = node_modules/libflacjs/dist/min/
6+
OLM_DIR = node_modules/olm
7+
RNNOISE_WASM_DIR = node_modules/rnnoise-wasm/dist/
8+
TFLITE_WASM = react/features/stream-effects/virtual-background/vendor/tflite
9+
MEET_MODELS_DIR = react/features/stream-effects/virtual-background/vendor/models/
10+
NODE_SASS = ./node_modules/.bin/sass
11+
NPM = npm
12+
OUTPUT_DIR = .
13+
STYLES_BUNDLE = css/all.bundle.css
14+
STYLES_DESTINATION = css/all.css
15+
STYLES_MAIN = css/main.scss
16+
WEBPACK = ./node_modules/.bin/webpack
17+
WEBPACK_DEV_SERVER = ./node_modules/.bin/webpack-dev-server
18+
19+
all: compile deploy clean
20+
21+
compile: compile-load-test
22+
$(WEBPACK) -p
23+
24+
compile-load-test:
25+
${NPM} install --prefix resources/load-test && ${NPM} run build --prefix resources/load-test
26+
27+
clean:
28+
rm -fr $(BUILD_DIR)
29+
30+
.NOTPARALLEL:
31+
deploy: deploy-init deploy-appbundle deploy-rnnoise-binary deploy-tflite deploy-meet-models deploy-lib-jitsi-meet deploy-libflac deploy-olm deploy-css deploy-local
32+
33+
deploy-init:
34+
rm -fr $(DEPLOY_DIR)
35+
mkdir -p $(DEPLOY_DIR)
36+
37+
deploy-appbundle:
38+
cp \
39+
$(BUILD_DIR)/app.bundle.min.js \
40+
$(BUILD_DIR)/app.bundle.min.map \
41+
$(BUILD_DIR)/do_external_connect.min.js \
42+
$(BUILD_DIR)/do_external_connect.min.map \
43+
$(BUILD_DIR)/external_api.min.js \
44+
$(BUILD_DIR)/external_api.min.map \
45+
$(BUILD_DIR)/flacEncodeWorker.min.js \
46+
$(BUILD_DIR)/flacEncodeWorker.min.map \
47+
$(BUILD_DIR)/dial_in_info_bundle.min.js \
48+
$(BUILD_DIR)/dial_in_info_bundle.min.map \
49+
$(BUILD_DIR)/alwaysontop.min.js \
50+
$(BUILD_DIR)/alwaysontop.min.map \
51+
$(OUTPUT_DIR)/analytics-ga.js \
52+
$(BUILD_DIR)/analytics-ga.min.js \
53+
$(BUILD_DIR)/analytics-ga.min.map \
54+
$(BUILD_DIR)/close3.min.js \
55+
$(BUILD_DIR)/close3.min.map \
56+
$(DEPLOY_DIR)
57+
58+
deploy-lib-jitsi-meet:
59+
cp \
60+
$(LIBJITSIMEET_DIR)/lib-jitsi-meet.min.js \
61+
$(LIBJITSIMEET_DIR)/lib-jitsi-meet.min.map \
62+
$(LIBJITSIMEET_DIR)/lib-jitsi-meet.e2ee-worker.js \
63+
$(LIBJITSIMEET_DIR)/connection_optimization/external_connect.js \
64+
$(LIBJITSIMEET_DIR)/modules/browser/capabilities.json \
65+
$(DEPLOY_DIR)
66+
67+
deploy-libflac:
68+
cp \
69+
$(LIBFLAC_DIR)/libflac4-1.3.2.min.js \
70+
$(LIBFLAC_DIR)/libflac4-1.3.2.min.js.mem \
71+
$(DEPLOY_DIR)
72+
73+
deploy-olm:
74+
cp \
75+
$(OLM_DIR)/olm.wasm \
76+
$(DEPLOY_DIR)
77+
78+
deploy-rnnoise-binary:
79+
cp \
80+
$(RNNOISE_WASM_DIR)/rnnoise.wasm \
81+
$(DEPLOY_DIR)
82+
83+
deploy-tflite:
84+
cp \
85+
$(TFLITE_WASM)/*.wasm \
86+
$(DEPLOY_DIR)
87+
88+
deploy-meet-models:
89+
cp \
90+
$(MEET_MODELS_DIR)/*.tflite \
91+
$(DEPLOY_DIR)
92+
93+
deploy-css:
94+
$(NODE_SASS) $(STYLES_MAIN) $(STYLES_BUNDLE) && \
95+
$(CLEANCSS) --skip-rebase $(STYLES_BUNDLE) > $(STYLES_DESTINATION) ; \
96+
rm $(STYLES_BUNDLE)
97+
98+
deploy-local:
99+
([ ! -x deploy-local.sh ] || ./deploy-local.sh)
100+
101+
.NOTPARALLEL:
102+
dev: deploy-init deploy-css deploy-rnnoise-binary deploy-tflite deploy-meet-models deploy-lib-jitsi-meet deploy-libflac deploy-olm
103+
$(WEBPACK_DEV_SERVER) --detect-circular-deps
104+
105+
source-package:
106+
mkdir -p source_package/jitsi-meet/css && \
107+
cp -r *.js *.html resources/*.txt connection_optimization favicon.ico fonts images libs static sounds LICENSE lang source_package/jitsi-meet && \
108+
cp css/all.css source_package/jitsi-meet/css && \
109+
(cd source_package ; tar cjf ../jitsi-meet.tar.bz2 jitsi-meet) && \
110+
rm -rf source_package

SECURITY.md

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# Security
2+
3+
## Reporting security issues
4+
5+
We take security very seriously and develop all Jitsi projects to be secure and safe.
6+
7+
If you find (or simply suspect) a security issue in any of the Jitsi projects, please report it to us via [HackerOne](https://hackerone.com/8x8) or send us an email to [email protected].
8+
9+
**We encourage responsible disclosure for the sake of our users, so please reach out before posting in a public space.**

0 commit comments

Comments
 (0)