Move js sources to /src and use /js for the bundle
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
This commit is contained in:
Родитель
040085fb03
Коммит
dfe651eee4
|
@ -2,10 +2,6 @@
|
|||
composer.phar
|
||||
/vendor/
|
||||
|
||||
# Unnecessary bower dependency files
|
||||
/js/vendor/jquery/src/*
|
||||
/js/vendor/ical.js/samples/*
|
||||
|
||||
# Mac OS
|
||||
.DS_Store
|
||||
|
||||
|
@ -15,11 +11,7 @@ tests/clover.xml
|
|||
# Node.js modules
|
||||
node_modules/
|
||||
|
||||
# optimized JS files
|
||||
# Old r.js
|
||||
js/mail.min.js
|
||||
# new webpack
|
||||
/js/build
|
||||
/js
|
||||
|
||||
# packaged app
|
||||
build/artifacts
|
||||
|
|
|
@ -6,12 +6,12 @@
|
|||
"license": "agpl",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"build": "webpack --progress --hide-modules --config js/webpack.prod.js",
|
||||
"dev": "webpack --progress --watch --config js/webpack.dev.js",
|
||||
"build": "webpack --progress --hide-modules --config src/webpack.prod.js",
|
||||
"dev": "webpack --progress --watch --config src/webpack.dev.js",
|
||||
"lint": "$(npm bin)/eslint --ext .js,.vue js",
|
||||
"lint:autofix": "eslint --ext .js,.vue js --fix",
|
||||
"test": "mocha-webpack --webpack-config js/webpack.test.js --require js/tests/setup.js js/tests/**/*.spec.js",
|
||||
"test:watch": "mocha-webpack -w --webpack-config js/webpack.test.js --require js/tests/setup.js js/tests/**/*.spec.js"
|
||||
"test": "mocha-webpack --webpack-config src/webpack.test.js --require src/tests/setup.js src/tests/**/*.spec.js",
|
||||
"test:watch": "mocha-webpack -w --webpack-config src/webpack.test.js --require src/tests/setup.js src/tests/**/*.spec.js"
|
||||
},
|
||||
"dependencies": {
|
||||
"@vue/babel-preset-app": "^3.0.5",
|
||||
|
|
|
@ -4,8 +4,8 @@ const { VueLoaderPlugin } = require('vue-loader');
|
|||
module.exports = {
|
||||
entry: path.join(__dirname, 'main.js'),
|
||||
output: {
|
||||
path: path.resolve(__dirname, 'build'),
|
||||
publicPath: '/build/',
|
||||
path: path.resolve(__dirname, '..', 'js'),
|
||||
publicPath: '/js/',
|
||||
filename: 'mail.js'
|
||||
},
|
||||
module: {
|
|
@ -25,7 +25,7 @@
|
|||
*/
|
||||
style('mail', 'mail');
|
||||
style('mail', 'mobile');
|
||||
script('mail', 'build/mail');
|
||||
script('mail', 'mail');
|
||||
?>
|
||||
|
||||
<input type="hidden" id="debug-mode" value="<?php p($_['debug'] ? 'true' : 'false'); ?>">
|
||||
|
|
Загрузка…
Ссылка в новой задаче