mirror of
https://github.com/tsl0922/ttyd.git
synced 2025-12-21 11:24:20 +01:00
Replace browserify with webpack
This commit is contained in:
36
html/webpack.config.js
Normal file
36
html/webpack.config.js
Normal file
@@ -0,0 +1,36 @@
|
||||
const ExtractTextPlugin = require("extract-text-webpack-plugin");
|
||||
|
||||
module.exports = {
|
||||
output: {
|
||||
filename: 'bundle.js'
|
||||
},
|
||||
module: {
|
||||
rules: [
|
||||
{
|
||||
test: /\.js$/,
|
||||
exclude: /node_modules\/(?!zmodem.js\/)/,
|
||||
use: {
|
||||
loader: 'babel-loader',
|
||||
options: {
|
||||
presets: ['env']
|
||||
}
|
||||
}
|
||||
}, {
|
||||
test: /\.scss$/,
|
||||
use: ExtractTextPlugin.extract({
|
||||
use: [{
|
||||
loader: "css-loader"
|
||||
}, {
|
||||
loader: "sass-loader"
|
||||
}],
|
||||
fallback: "style-loader"
|
||||
})
|
||||
}
|
||||
]
|
||||
},
|
||||
plugins: [
|
||||
new ExtractTextPlugin({
|
||||
filename: 'bundle.css',
|
||||
})
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user