Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/spreed.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Calviño Sánchez <danxuliu@gmail.com>2019-12-12 10:21:56 +0300
committerJoas Schilling <coding@schilljs.com>2019-12-13 23:05:25 +0300
commit3f56ae160638ef37e1040b1f16e544ddddca559a (patch)
treee9bb5be2dc56b831444f4f69b1d96ca4dce709be /webpack.common.js
parent82b486585093beb82e08c57b13953536d8ddb453 (diff)
Import custom version of SimpleWebRTC
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
Diffstat (limited to 'webpack.common.js')
-rw-r--r--webpack.common.js21
1 files changed, 21 insertions, 0 deletions
diff --git a/webpack.common.js b/webpack.common.js
index e20bb387d..f3d5a2f07 100644
--- a/webpack.common.js
+++ b/webpack.common.js
@@ -47,6 +47,27 @@ module.exports = {
exclude: /node_modules/
},
{
+ /**
+ * webrtc-adapter main module does no longer provide
+ * "module.exports", which is expected by some elements using it
+ * (like "attachmediastream"), so it needs to be added back with
+ * a plugin.
+ */
+ test: /node_modules\/webrtc-adapter\/.*\.js$/,
+ loader: 'babel-loader',
+ options: {
+ plugins: ['add-module-exports'],
+ presets: [
+ /**
+ * From "add-module-exports" documentation:
+ * "webpack doesn't perform commonjs transformation for
+ * codesplitting. Need to set commonjs conversion."
+ */
+ ['@babel/env', { modules: 'commonjs' }]
+ ]
+ }
+ },
+ {
test: /\.(png|jpg|gif|svg)$/,
loader: 'file-loader',
options: {