第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定

打包時(shí)報(bào)錯(cuò)

打包時(shí)報(bào)錯(cuò)


ERROR in ./node_modules/.bin/webpack 1:0

Module parse failed: Unexpected character '#' (1:0)

You may need an appropriate loader to handle this file type.

> #!/bin/sh

| basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")

|

Child html-webpack-plugin for "index.html":

? ? ?1 asset

? ? Entrypoint undefined = index.html

? ? ? ?4 modules


正在回答

2 回答

const?path?=?require('path')
const?VueLoaderPlugin?=?require('vue-loader/lib/plugin')
const?isDev?=?process.env.NODE_ENV?===?'development';
const?HTMLPlugin?=?require('html-webpack-plugin');
const?webpack?=?require('webpack');
//?const?ExtractPlugin=require('mini-css-extract-plugin')
const?ExtractPlugin=require('extract-text-webpack-plugin')
//?ExtractPlugin
//?const?MiniCssExtractPlugin?=?require('mini-css-extract-plugin')
//?定義輸出模塊
//?module.exports
const?config??={
target:'web',
//?拼接路徑,使其成為絕對(duì)路徑
entry:?path.join(__dirname,'./src/index.js'),
output:?{
????filename:?'bundle.js',
????path:?path.join(__dirname,'./dist')
},
module:?{
????rules:?[
??????{
????????test:?/\.vue$/,
????????loader:?'vue-loader'
??????},
??????{
????????test:?/\.css$/,
????????use:?[
????????'style-loader',
????????'css-loader'
????????]
??????},
{
test:/\.styl(us)?$/,
????????use:?ExtractPlugin.extract({
????????fallback:?'style-loader',
????????use:[
??????????{loader:'css-loader'},
{
loader?:?'postcss-loader',
options:??{
sourceMap:?true,
}
},
??????????{loader:'stylus-loader'}
????????]
????????})
},
??????{
????????test:?/\.jsx$/,
????????loader:?'babel-loader'
??????},
??????{
????????test:?/\.(gif|jpg|jpeg|png|svg)$/,
????????use:?[
??????????{
????????????loader:?'url-loader',
????????????options:{
??????????????limit:?1024,
??????????????name:?'[name].[ext]'
????????????}
??????????}
????????]
??????}
????]
},
??plugins:?[
new?webpack.DefinePlugin({

'process.env':?{
NODE_ENV:isDev?'"development"'?:'"production"'
}
}),
????//?請(qǐng)確保引入這個(gè)插件!
????new?VueLoaderPlugin(),
????new?HTMLPlugin(),
??]
}
if?(isDev)?{
//頁面調(diào)試工具?
config.devtool?=?'#cheap-module-eval-source-map'
//?開發(fā)環(huán)境端口
config.devServer?=?{
port:?8000,
????host:'0.0.0.0',
????historyApiFallback:true,
????overlay:?{
??????errors:true,
????},
//?熱加載,只渲染改變的組件,不需要重新渲染整個(gè)頁面
//?hot:?true不要和new?webpack.HotModuleReplacementPlugin()同時(shí)啟用
hot:?true
//?open:true
},
//?熱加載所需配置
config.plugins.push(
????//?new?webpack.HotModuleReplacementPlugin(),
????new?webpack.NoEmitOnErrorsPlugin()
??)
}
module.exports?=?config


0 回復(fù) 有任何疑惑可以回復(fù)我~

123

0 回復(fù) 有任何疑惑可以回復(fù)我~

舉報(bào)

0/150
提交
取消

打包時(shí)報(bào)錯(cuò)

我要回答 關(guān)注問題
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)