mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-07-13 03:27:39 +03:00
Update dependencies and configurations
This commit is contained in:
parent
dbbc83e4c8
commit
a1562e7145
18 changed files with 732 additions and 633 deletions
4
.browserslistrc
Normal file
4
.browserslistrc
Normal file
|
|
@ -0,0 +1,4 @@
|
||||||
|
last 3 version
|
||||||
|
> 1%
|
||||||
|
ie >= 9
|
||||||
|
firefox esr
|
||||||
2
.cmds
2
.cmds
|
|
@ -6,7 +6,7 @@ yarn upgrade xxx@1.2.3
|
||||||
# transifex
|
# transifex
|
||||||
tx pull -a
|
tx pull -a
|
||||||
|
|
||||||
# dependencies
|
# dependencies
|
||||||
yarn outdated
|
yarn outdated
|
||||||
yarn upgrade-interactive --exact --latest
|
yarn upgrade-interactive --exact --latest
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
FROM node:9.11.2-alpine
|
FROM node:10.16.0-alpine
|
||||||
|
|
||||||
RUN apk add --no-cache git
|
RUN apk add --no-cache git
|
||||||
RUN yarn global add gulp@3.9.1
|
RUN yarn global add gulp@3.9.1
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ module.exports = {
|
||||||
"parser": "babel-eslint",
|
"parser": "babel-eslint",
|
||||||
'parserOptions': {
|
'parserOptions': {
|
||||||
'ecmaVersion': 6,
|
'ecmaVersion': 6,
|
||||||
'sourceType': 'module'
|
'sourceType': 'module'
|
||||||
},
|
},
|
||||||
'env': {
|
'env': {
|
||||||
'node': true,
|
'node': true,
|
||||||
'commonjs': true,
|
'commonjs': true,
|
||||||
|
|
|
||||||
|
|
@ -26,4 +26,4 @@ Information about installing the product, check the [documentation page](http://
|
||||||
**GNU AFFERO GENERAL PUBLIC LICENSE Version 3 (AGPL)**.
|
**GNU AFFERO GENERAL PUBLIC LICENSE Version 3 (AGPL)**.
|
||||||
http://www.gnu.org/licenses/agpl-3.0.html
|
http://www.gnu.org/licenses/agpl-3.0.html
|
||||||
|
|
||||||
Copyright (c) 2018 Rainloop Team
|
Copyright (c) 2019 Rainloop Team
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
* ownCloud/Nextcloud - RainLoop Webmail package
|
* ownCloud/Nextcloud - RainLoop Webmail package
|
||||||
*
|
*
|
||||||
* @author RainLoop Team
|
* @author RainLoop Team
|
||||||
* @copyright 2018 RainLoop Team
|
* @copyright 2019 RainLoop Team
|
||||||
*
|
*
|
||||||
* https://github.com/RainLoop/rainloop-webmail/tree/master/build/owncloud
|
* https://github.com/RainLoop/rainloop-webmail/tree/master/build/owncloud
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -201,6 +201,7 @@ class AbstractAjaxRemote
|
||||||
this.oRequests[action] = oDefAjax;
|
this.oRequests[action] = oDefAjax;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
oDefAjax.catch(console.log);
|
||||||
return oDefAjax;
|
return oDefAjax;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
15
dev/boot.js
15
dev/boot.js
|
|
@ -1,13 +1,12 @@
|
||||||
|
import elementDatasetPolyfill from 'element-dataset';
|
||||||
|
elementDatasetPolyfill();
|
||||||
|
|
||||||
|
require('json3');
|
||||||
|
require('intersection-observer');
|
||||||
|
|
||||||
import window from 'window';
|
import window from 'window';
|
||||||
import elementDatasetPolyfill from 'element-dataset';
|
|
||||||
|
|
||||||
import 'es6-object-assign/auto';
|
|
||||||
|
|
||||||
import {Promise} from 'es6-promise-polyfill/promise.js';
|
|
||||||
import {progressJs} from '../vendors/Progress.js/src/progress.js';
|
import {progressJs} from '../vendors/Progress.js/src/progress.js';
|
||||||
|
|
||||||
window.Promise = window.Promise || Promise;
|
|
||||||
window.progressJs = window.progressJs || progressJs();
|
window.progressJs = window.progressJs || progressJs();
|
||||||
|
|
||||||
window.progressJs.onbeforeend(() => {
|
window.progressJs.onbeforeend(() => {
|
||||||
|
|
@ -24,10 +23,6 @@ window.progressJs.onbeforeend(() => {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
elementDatasetPolyfill();
|
|
||||||
|
|
||||||
require('json3');
|
|
||||||
require('intersection-observer');
|
|
||||||
require('../vendors/modernizr/modernizr-custom.js');
|
require('../vendors/modernizr/modernizr-custom.js');
|
||||||
require('Common/Booter');
|
require('Common/Booter');
|
||||||
|
|
||||||
|
|
|
||||||
15
dev/polyfills.js
Normal file
15
dev/polyfills.js
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
import 'core-js/features/object/assign';
|
||||||
|
import 'core-js/features/array/includes';
|
||||||
|
import 'core-js/features/string/includes';
|
||||||
|
import 'core-js/features/promise';
|
||||||
|
import 'raf/polyfill';
|
||||||
|
|
||||||
|
/* eslint-disable no-undefined, consistent-return */
|
||||||
|
const log = console && console.log ? console.log : undefined;
|
||||||
|
console.log = log ? (...props) => {
|
||||||
|
if (props && props[0] && 0 === props[0].indexOf('JQMIGRATE:')) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
return log(...props);
|
||||||
|
} : undefined;
|
||||||
15
gulpfile.js
15
gulpfile.js
|
|
@ -44,7 +44,6 @@ var
|
||||||
rename = require('gulp-rename'),
|
rename = require('gulp-rename'),
|
||||||
replace = require('gulp-replace'),
|
replace = require('gulp-replace'),
|
||||||
uglify = require('gulp-uglify'),
|
uglify = require('gulp-uglify'),
|
||||||
notify = require("gulp-notify"),
|
|
||||||
plumber = require('gulp-plumber'),
|
plumber = require('gulp-plumber'),
|
||||||
gulpif = require('gulp-if'),
|
gulpif = require('gulp-if'),
|
||||||
eol = require('gulp-eol'),
|
eol = require('gulp-eol'),
|
||||||
|
|
@ -98,12 +97,6 @@ function webpackError(err) {
|
||||||
gutil.log('[webpack]', err.error ? err.error.toString() : '');
|
gutil.log('[webpack]', err.error ? err.error.toString() : '');
|
||||||
gutil.log('[webpack]', err.message || '');
|
gutil.log('[webpack]', err.message || '');
|
||||||
gutil.log('[webpack]', '---');
|
gutil.log('[webpack]', '---');
|
||||||
|
|
||||||
notifier.notify({
|
|
||||||
'sound': true,
|
|
||||||
'title': 'webpack',
|
|
||||||
'message': err.error ? err.error.toString() : err.message
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -263,13 +256,13 @@ gulp.task('css:main', ['assets'], function() {
|
||||||
return gulp.src(src)
|
return gulp.src(src)
|
||||||
.pipe(expect.real({errorOnFailure: true}, src))
|
.pipe(expect.real({errorOnFailure: true}, src))
|
||||||
.pipe(lessFilter)
|
.pipe(lessFilter)
|
||||||
.pipe(gulpif(cfg.watch, plumber({errorHandler: notify.onError("Error: <%= error.message %>")})))
|
.pipe(gulpif(cfg.watch, plumber()))
|
||||||
.pipe(less({
|
.pipe(less({
|
||||||
'paths': cfg.paths.less.main.options.paths
|
'paths': cfg.paths.less.main.options.paths
|
||||||
}))
|
}))
|
||||||
.pipe(lessFilter.restore)
|
.pipe(lessFilter.restore)
|
||||||
.pipe(concat(cfg.paths.css.main.name))
|
.pipe(concat(cfg.paths.css.main.name))
|
||||||
.pipe(autoprefixer('last 3 versions', 'ie >= 9', 'Firefox ESR'))
|
.pipe(autoprefixer())
|
||||||
.pipe(replace(/\.\.\/(img|images|fonts|svg)\//g, '$1/'))
|
.pipe(replace(/\.\.\/(img|images|fonts|svg)\//g, '$1/'))
|
||||||
.pipe(eol('\n', true))
|
.pipe(eol('\n', true))
|
||||||
.pipe(gulp.dest(cfg.paths.staticCSS))
|
.pipe(gulp.dest(cfg.paths.staticCSS))
|
||||||
|
|
@ -282,7 +275,7 @@ gulp.task('css:social', function() {
|
||||||
return gulp.src(src)
|
return gulp.src(src)
|
||||||
.pipe(expect.real({errorOnFailure: true}, src))
|
.pipe(expect.real({errorOnFailure: true}, src))
|
||||||
.pipe(concat(cfg.paths.css.social.name))
|
.pipe(concat(cfg.paths.css.social.name))
|
||||||
.pipe(autoprefixer('last 3 versions', 'ie >= 9', 'Firefox ESR'))
|
.pipe(autoprefixer())
|
||||||
.pipe(replace(/\.\.\/(img|images|fonts|svg)\//g, '$1/'))
|
.pipe(replace(/\.\.\/(img|images|fonts|svg)\//g, '$1/'))
|
||||||
.pipe(eol('\n', true))
|
.pipe(eol('\n', true))
|
||||||
.pipe(gulp.dest(cfg.paths.staticCSS));
|
.pipe(gulp.dest(cfg.paths.staticCSS));
|
||||||
|
|
@ -380,7 +373,7 @@ gulp.task('js:eslint', function() {
|
||||||
return gulp.src(cfg.paths.globjs)
|
return gulp.src(cfg.paths.globjs)
|
||||||
.pipe(cache('eslint'))
|
.pipe(cache('eslint'))
|
||||||
.pipe(eslint())
|
.pipe(eslint())
|
||||||
.pipe(gulpif(cfg.watch, plumber({errorHandler: notify.onError("Error: <%= error.message %>")})))
|
.pipe(gulpif(cfg.watch, plumber()))
|
||||||
.pipe(eslint.format())
|
.pipe(eslint.format())
|
||||||
.pipe(eslint.failAfterError());
|
.pipe(eslint.failAfterError());
|
||||||
});
|
});
|
||||||
|
|
|
||||||
58
package.json
58
package.json
|
|
@ -3,8 +3,8 @@
|
||||||
"title": "RainLoop Webmail",
|
"title": "RainLoop Webmail",
|
||||||
"description": "Simple, modern & fast web-based email client",
|
"description": "Simple, modern & fast web-based email client",
|
||||||
"private": true,
|
"private": true,
|
||||||
"version": "1.12.1",
|
"version": "1.13.0",
|
||||||
"ownCloudVersion": "5.1.1",
|
"ownCloudVersion": "5.2.0",
|
||||||
"homepage": "https://www.rainloop.net",
|
"homepage": "https://www.rainloop.net",
|
||||||
"author": {
|
"author": {
|
||||||
"name": "RainLoop Team",
|
"name": "RainLoop Team",
|
||||||
|
|
@ -46,31 +46,26 @@
|
||||||
"openpgp"
|
"openpgp"
|
||||||
],
|
],
|
||||||
"readmeFilename": "README.md",
|
"readmeFilename": "README.md",
|
||||||
"browserslist": [
|
|
||||||
"last 3 versions",
|
|
||||||
"IE >= 9",
|
|
||||||
"firefox esr"
|
|
||||||
],
|
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@babel/core": "7.4.0",
|
"@babel/core": "7.4.5",
|
||||||
"@babel/plugin-proposal-class-properties": "7.4.0",
|
"@babel/plugin-proposal-class-properties": "7.4.4",
|
||||||
"@babel/plugin-proposal-decorators": "7.4.0",
|
"@babel/plugin-proposal-decorators": "7.4.4",
|
||||||
"@babel/plugin-transform-runtime": "7.4.0",
|
"@babel/plugin-transform-runtime": "7.4.4",
|
||||||
"@babel/preset-env": "7.4.2",
|
"@babel/preset-env": "7.4.5",
|
||||||
"@babel/runtime-corejs2": "7.4.2",
|
"@babel/runtime": "7.4.5",
|
||||||
"autolinker": "3.0.5",
|
"@babel/runtime-corejs3": "7.4.5",
|
||||||
"babel-eslint": "10.0.1",
|
"autolinker": "3.1.0",
|
||||||
"babel-loader": "8.0.5",
|
"babel-eslint": "10.0.2",
|
||||||
|
"babel-loader": "8.0.6",
|
||||||
"classnames": "2.2.6",
|
"classnames": "2.2.6",
|
||||||
"copy-webpack-plugin": "5.0.2",
|
"copy-webpack-plugin": "5.0.3",
|
||||||
"css-loader": "2.1.1",
|
"core-js": "3.1.4",
|
||||||
|
"css-loader": "3.0.0",
|
||||||
"element-dataset": "2.2.6",
|
"element-dataset": "2.2.6",
|
||||||
"emailjs-addressparser": "2.0.2",
|
"emailjs-addressparser": "2.0.2",
|
||||||
"es6-object-assign": "1.1.0",
|
"eslint": "6.0.1",
|
||||||
"es6-promise-polyfill": "1.2.0",
|
|
||||||
"eslint": "5.15.3",
|
|
||||||
"gulp": "3.9.1",
|
"gulp": "3.9.1",
|
||||||
"gulp-autoprefixer": "6.0.0",
|
"gulp-autoprefixer": "6.1.0",
|
||||||
"gulp-cached": "1.1.1",
|
"gulp-cached": "1.1.1",
|
||||||
"gulp-chmod": "2.0.0",
|
"gulp-chmod": "2.0.0",
|
||||||
"gulp-clean-css": "3.10.0",
|
"gulp-clean-css": "3.10.0",
|
||||||
|
|
@ -83,7 +78,6 @@
|
||||||
"gulp-if": "2.0.2",
|
"gulp-if": "2.0.2",
|
||||||
"gulp-less": "4.0.1",
|
"gulp-less": "4.0.1",
|
||||||
"gulp-livereload": "4.0.1",
|
"gulp-livereload": "4.0.1",
|
||||||
"gulp-notify": "3.2.0",
|
|
||||||
"gulp-plumber": "1.2.1",
|
"gulp-plumber": "1.2.1",
|
||||||
"gulp-rename": "1.4.0",
|
"gulp-rename": "1.4.0",
|
||||||
"gulp-replace": "1.0.0",
|
"gulp-replace": "1.0.0",
|
||||||
|
|
@ -95,20 +89,20 @@
|
||||||
"gulp-util": "3.0.8",
|
"gulp-util": "3.0.8",
|
||||||
"gulp-zip": "4.2.0",
|
"gulp-zip": "4.2.0",
|
||||||
"ifvisible.js": "1.0.6",
|
"ifvisible.js": "1.0.6",
|
||||||
"intersection-observer": "0.5.1",
|
"intersection-observer": "0.7.0",
|
||||||
"jquery": "3.3.1",
|
"jquery": "3.4.1",
|
||||||
"jquery-backstretch": "2.1.17",
|
"jquery-backstretch": "2.1.17",
|
||||||
"jquery-migrate": "3.0.1",
|
"jquery-migrate": "3.1.0",
|
||||||
"jquery-mousewheel": "3.1.13",
|
"jquery-mousewheel": "3.1.13",
|
||||||
"jquery-scrollstop": "1.2.0",
|
"jquery-scrollstop": "1.2.0",
|
||||||
"js-cookie": "2.2.0",
|
"js-cookie": "2.2.0",
|
||||||
"json-loader": "0.5.7",
|
"json-loader": "0.5.7",
|
||||||
"json3": "3.3.2",
|
"json3": "3.3.3",
|
||||||
"knockout": "3.4.2",
|
"knockout": "3.4.2",
|
||||||
"knockout-sortable": "1.1.1",
|
"knockout-sortable": "1.1.1",
|
||||||
"knockout-transformations": "2.1.0",
|
"knockout-transformations": "2.1.0",
|
||||||
"lozad": "1.9.0",
|
"lozad": "1.9.0",
|
||||||
"matchmedia-polyfill": "0.3.1",
|
"matchmedia-polyfill": "0.3.2",
|
||||||
"moment": "2.24.0",
|
"moment": "2.24.0",
|
||||||
"node-fs": "0.1.7",
|
"node-fs": "0.1.7",
|
||||||
"node-notifier": "5.4.0",
|
"node-notifier": "5.4.0",
|
||||||
|
|
@ -116,14 +110,14 @@
|
||||||
"openpgp": "2.6.2",
|
"openpgp": "2.6.2",
|
||||||
"opentip": "2.4.3",
|
"opentip": "2.4.3",
|
||||||
"pikaday": "1.8.0",
|
"pikaday": "1.8.0",
|
||||||
"raw-loader": "2.0.0",
|
"raf": "3.4.1",
|
||||||
|
"raw-loader": "3.0.0",
|
||||||
"rimraf": "2.6.3",
|
"rimraf": "2.6.3",
|
||||||
"run-sequence": "2.2.1",
|
"run-sequence": "2.2.1",
|
||||||
"simplestatemanager": "4.1.1",
|
"simplestatemanager": "4.1.1",
|
||||||
"style-loader": "0.23.1",
|
"style-loader": "0.23.1",
|
||||||
"underscore": "1.9.1",
|
"underscore": "1.9.1",
|
||||||
"webpack": "4.29.6",
|
"webpack": "4.35.0",
|
||||||
"webpack-cli": "3.3.0",
|
"webpack-cli": "3.3.5"
|
||||||
"webpack-notifier": "1.7.0"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -301,6 +301,7 @@ class Service
|
||||||
'{{BaseAppFaviconTouchLinkTag}}' => $sAppleTouchLink ? '<link type="image/png" rel="apple-touch-icon" href="'.$sAppleTouchLink.'" />' : '',
|
'{{BaseAppFaviconTouchLinkTag}}' => $sAppleTouchLink ? '<link type="image/png" rel="apple-touch-icon" href="'.$sAppleTouchLink.'" />' : '',
|
||||||
'{{BaseAppMainCssLink}}' => $this->staticPath('css/app'.($bAppCssDebug ? '' : '.min').'.css'),
|
'{{BaseAppMainCssLink}}' => $this->staticPath('css/app'.($bAppCssDebug ? '' : '.min').'.css'),
|
||||||
'{{BaseAppThemeCssLink}}' => $this->oActions->ThemeLink($sTheme, $bAdmin),
|
'{{BaseAppThemeCssLink}}' => $this->oActions->ThemeLink($sTheme, $bAdmin),
|
||||||
|
'{{BaseAppPolyfillsScriptLink}}' => $this->staticPath('js/'.($bAppJsDebug ? '' : 'min/').'polyfills'.($bAppJsDebug ? '' : '.min').'.js'),
|
||||||
'{{BaseAppBootScriptLink}}' => $this->staticPath('js/'.($bAppJsDebug ? '' : 'min/').'boot'.($bAppJsDebug ? '' : '.min').'.js'),
|
'{{BaseAppBootScriptLink}}' => $this->staticPath('js/'.($bAppJsDebug ? '' : 'min/').'boot'.($bAppJsDebug ? '' : '.min').'.js'),
|
||||||
'{{BaseViewport}}' => $bMobile ? 'width=device-width,initial-scale=1,user-scalable=no' : 'width=950,maximum-scale=2',
|
'{{BaseViewport}}' => $bMobile ? 'width=device-width,initial-scale=1,user-scalable=no' : 'width=950,maximum-scale=2',
|
||||||
'{{BaseContentSecurityPolicy}}' => $sContentSecurityPolicy ?
|
'{{BaseContentSecurityPolicy}}' => $sContentSecurityPolicy ?
|
||||||
|
|
|
||||||
|
|
@ -14,6 +14,7 @@
|
||||||
<meta name="google" content="notranslate" />
|
<meta name="google" content="notranslate" />
|
||||||
<meta name="robots" content="noindex,nofollow,noodp" />
|
<meta name="robots" content="noindex,nofollow,noodp" />
|
||||||
<meta name="AppBootData" content='{{RainloopBootData}}' id="app-boot-data" />
|
<meta name="AppBootData" content='{{RainloopBootData}}' id="app-boot-data" />
|
||||||
|
<script type="text/javascript" data-cfasync="false" src="{{BaseAppPolyfillsScriptLink}}"></script>
|
||||||
{{BaseContentSecurityPolicy}}
|
{{BaseContentSecurityPolicy}}
|
||||||
<title></title>
|
<title></title>
|
||||||
{{BaseAppHeadScriptLink}}
|
{{BaseAppHeadScriptLink}}
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@
|
||||||
<div class="span4">
|
<div class="span4">
|
||||||
<div class="rl-logo"></div>
|
<div class="rl-logo"></div>
|
||||||
<div style="margin-left: 30px;">
|
<div style="margin-left: 30px;">
|
||||||
2018 © <span data-i18n="TAB_ABOUT/LABEL_ALL_RIGHTS_RESERVED"></span>
|
2019 © <span data-i18n="TAB_ABOUT/LABEL_ALL_RIGHTS_RESERVED"></span>
|
||||||
<br />
|
<br />
|
||||||
<a class="g-ui-link" href="http://www.rainloop.net/" target="_blank" style="padding-left: 0">http://rainloop.net/</a>
|
<a class="g-ui-link" href="http://www.rainloop.net/" target="_blank" style="padding-left: 0">http://rainloop.net/</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -8,9 +8,11 @@
|
||||||
<td class="package-version-parent">
|
<td class="package-version-parent">
|
||||||
<span class="package-version" data-bind="text: version"></span>
|
<span class="package-version" data-bind="text: version"></span>
|
||||||
</td>
|
</td>
|
||||||
|
<!--
|
||||||
<td class="package-release-parent">
|
<td class="package-release-parent">
|
||||||
<span class="package-release" data-bind="text: release"></span>
|
<span class="package-release" data-bind="text: release"></span>
|
||||||
</td>
|
</td>
|
||||||
|
-->
|
||||||
<td class="package-actions-parent">
|
<td class="package-actions-parent">
|
||||||
<i class="icon-download e-action button-download" data-bind="visible: !loading() && canBeUpdated, click: function () { $root.installPackage($data); }"></i>
|
<i class="icon-download e-action button-download" data-bind="visible: !loading() && canBeUpdated, click: function () { $root.installPackage($data); }"></i>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
<colgroup>
|
<colgroup>
|
||||||
<col />
|
<col />
|
||||||
<col style="width: 100px" />
|
<col style="width: 100px" />
|
||||||
<col style="width: 100px" />
|
<!-- <col style="width: 100px" /> -->
|
||||||
<col style="width: 80px" />
|
<col style="width: 80px" />
|
||||||
</colgroup>
|
</colgroup>
|
||||||
<tbody data-bind="template: { name: 'AdminSettingsPackagesListItem', foreach: f }"></tbody>
|
<tbody data-bind="template: { name: 'AdminSettingsPackagesListItem', foreach: f }"></tbody>
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,6 @@ const
|
||||||
webpack = require('webpack'),
|
webpack = require('webpack'),
|
||||||
|
|
||||||
CopyWebpackPlugin = require('copy-webpack-plugin'),
|
CopyWebpackPlugin = require('copy-webpack-plugin'),
|
||||||
WebpackNotifierPlugin = require('webpack-notifier'),
|
|
||||||
|
|
||||||
devPath = path.resolve(__dirname, 'dev'),
|
devPath = path.resolve(__dirname, 'dev'),
|
||||||
devPathJoin = path.join(__dirname, 'dev'),
|
devPathJoin = path.join(__dirname, 'dev'),
|
||||||
|
|
@ -13,19 +12,25 @@ const
|
||||||
|
|
||||||
const babelLoaderOptions = function() {
|
const babelLoaderOptions = function() {
|
||||||
return {
|
return {
|
||||||
|
ignore: [
|
||||||
|
/\/core-js/
|
||||||
|
],
|
||||||
cacheDirectory: true,
|
cacheDirectory: true,
|
||||||
|
overrides: [{
|
||||||
|
test: './node_modules/',
|
||||||
|
sourceType: 'unambiguous'
|
||||||
|
}],
|
||||||
presets: [
|
presets: [
|
||||||
['@babel/preset-env', {
|
['@babel/preset-env', {
|
||||||
|
useBuiltIns: 'usage',
|
||||||
|
corejs: {version: 3, proposals: true},
|
||||||
loose: loose,
|
loose: loose,
|
||||||
modules: false,
|
modules: false
|
||||||
targets: {
|
|
||||||
browsers: ['last 3 versions', 'ie >= 9', 'firefox esr']
|
|
||||||
}
|
|
||||||
}]
|
}]
|
||||||
],
|
],
|
||||||
plugins: [
|
plugins: [
|
||||||
['@babel/plugin-transform-runtime', {
|
['@babel/plugin-transform-runtime', {
|
||||||
corejs: 2
|
corejs: 3
|
||||||
}],
|
}],
|
||||||
['@babel/plugin-proposal-decorators', {
|
['@babel/plugin-proposal-decorators', {
|
||||||
legacy: true
|
legacy: true
|
||||||
|
|
@ -40,6 +45,7 @@ module.exports = function(publicPath, pro, mode) {
|
||||||
return {
|
return {
|
||||||
mode: mode || 'development',
|
mode: mode || 'development',
|
||||||
entry: {
|
entry: {
|
||||||
|
'js/polyfills': path.join(devPathJoin, 'polyfills.js'),
|
||||||
'js/boot': path.join(devPathJoin, 'boot.js'),
|
'js/boot': path.join(devPathJoin, 'boot.js'),
|
||||||
'js/app': path.join(devPathJoin, 'app.js'),
|
'js/app': path.join(devPathJoin, 'app.js'),
|
||||||
'js/admin': path.join(devPathJoin, 'admin.js')
|
'js/admin': path.join(devPathJoin, 'admin.js')
|
||||||
|
|
@ -60,11 +66,13 @@ module.exports = function(publicPath, pro, mode) {
|
||||||
plugins: [
|
plugins: [
|
||||||
new webpack.DefinePlugin({
|
new webpack.DefinePlugin({
|
||||||
'RL_COMMUNITY': !pro,
|
'RL_COMMUNITY': !pro,
|
||||||
|
'process.env.NODE_ENV': JSON.stringify('production'),
|
||||||
'process.env': {
|
'process.env': {
|
||||||
NODE_ENV: '"production"'
|
NODE_ENV: JSON.stringify('production')
|
||||||
}
|
}
|
||||||
}),
|
}),
|
||||||
new WebpackNotifierPlugin(),
|
new webpack.DefinePlugin({
|
||||||
|
}),
|
||||||
new CopyWebpackPlugin([
|
new CopyWebpackPlugin([
|
||||||
{from: 'node_modules/openpgp/dist/openpgp.min.js', to: 'js/min/openpgp.min.js'},
|
{from: 'node_modules/openpgp/dist/openpgp.min.js', to: 'js/min/openpgp.min.js'},
|
||||||
{from: 'node_modules/openpgp/dist/openpgp.worker.min.js', to: 'js/min/openpgp.worker.min.js'}
|
{from: 'node_modules/openpgp/dist/openpgp.worker.min.js', to: 'js/min/openpgp.worker.min.js'}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue