瀏覽代碼

Simplify Webpack's configuration

Using both include and test for a loader which is to process a single
file is more complex than necessary. Reduce that to a test only.
dev1
Hristo Terezov 9 年之前
父節點
當前提交
bea6a54911
共有 1 個檔案被更改,包括 1 行新增2 行删除
  1. 1
    2
      webpack.config.babel.js

+ 1
- 2
webpack.config.babel.js 查看文件

@@ -16,7 +16,6 @@ export default {
16 16
         loaders: [ {
17 17
             // Version this build of the lib-jitsi-meet library.
18 18
 
19
-            include: `${__dirname}/JitsiMeetJS.js`,
20 19
             loader: 'string-replace',
21 20
             query: {
22 21
                 flags: 'g',
@@ -33,7 +32,7 @@ export default {
33 32
                             .trim(),
34 33
                 search: '{#COMMIT_HASH#}'
35 34
             },
36
-            test: /\.js$/
35
+            test: `${__dirname}/JitsiMeetJS.js`
37 36
         }, {
38 37
             // Transpile ES2015 (aka ES6) to ES5.
39 38
 

Loading…
取消
儲存