Skip to content
Snippets Groups Projects
Unverified Commit 58ecc7d0 authored by Roeland Jago Douma's avatar Roeland Jago Douma
Browse files

Move files_trashbin to webpack


Combine the 2 js files and the scss. This saves compiling the scss on
the go. And going via Nextcloud storage to obtain it.

Signed-off-by: default avatarRoeland Jago Douma <roeland@famdouma.nl>
parent eab46d1a
No related branches found
No related tags found
No related merge requests found
#webpack bundled files
js/files_trashbin.js
js/files_trashbin.js.map
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
File suppressed by a .gitattributes entry or the file's encoding is unsupported.
...@@ -34,7 +34,5 @@ $tmpl = new OCP\Template('files_trashbin', 'index', ''); ...@@ -34,7 +34,5 @@ $tmpl = new OCP\Template('files_trashbin', 'index', '');
// gridview not available for ie // gridview not available for ie
$tmpl->assign('showgridview', $showgridview && !$isIE); $tmpl->assign('showgridview', $showgridview && !$isIE);
OCP\Util::addStyle('files_trashbin', 'trash'); OCP\Util::addScript('files_trashbin', 'files_trashbin');
OCP\Util::addScript('files_trashbin', 'app');
OCP\Util::addScript('files_trashbin', 'filelist');
$tmpl->printPage(); $tmpl->printPage();
File moved
import './app'
import './filelist'
import './trash.scss'
window.OCA.Trashbin = OCA.Trashbin
const path = require('path');
module.exports = {
entry: path.join(__dirname, 'src', 'files_trashbin.js'),
output: {
path: path.resolve(__dirname, './js'),
publicPath: '/js/',
filename: 'files_trashbin.js'
},
module: {
rules: [
{
test: /\.css$/,
use: ['style-loader', 'css-loader']
},
{
test: /\.scss$/,
use: ['style-loader', 'css-loader', 'sass-loader']
},
{
test: /\.js$/,
loader: 'babel-loader',
exclude: /node_modules/
},
{
test: /\.(png|jpg|gif|svg)$/,
loader: 'file-loader',
options: {
name: '[name].[ext]?[hash]'
}
}
]
},
resolve: {
extensions: ['*', '.js']
}
};
const core = require('./core/webpack'); const core = require('./core/webpack');
const files_trashbin = require('./apps/files_trashbin/webpack')
const oauth2 = require('./apps/oauth2/webpack') const oauth2 = require('./apps/oauth2/webpack')
module.exports = [].concat(core, oauth2); module.exports = [].concat(core, files_trashbin, oauth2);
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment