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

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

老師能看一下為什么還會報(bào)錯(cuò)

ERROR in ./page/app.vue

Module build failed (from ./node_modules/css-loader/index.js):

Unknown word (2:19)


? 1 | <template>

> 2 |? ?<div id="test">{{text}}</div>

? ? |? ? ? ? ? ? ? ? ? ? ^

? 3 | </template>

? 4 | <script>

? 5 |? ?export default {


?@ ./page/index.js 2:0-27 8:18-21

npm ERR! code ELIFECYCLE

npm ERR! errno 2

npm ERR! wpc@1.0.0 build: `webpack --config webpack.config.js`

npm ERR! Exit status 2

npm ERR!

npm ERR! Failed at the wpc@1.0.0 build script.

npm ERR! This is probably not a problem with npm. There is likely additional logging output above.


npm ERR! A complete log of this run can be found in:

npm ERR!? ? ?C:\Users\Zuoqi Li\AppData\Roaming\npm-cache\_logs\2018-08-02T08_55_40_024Z-debug.log


C:\project\works_pro\wpc>npm i style-loader url-loader file-loader

npm WARN wpc@1.0.0 No description

npm WARN wpc@1.0.0 No repository field.

npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents):

npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

https://img1.sycdn.imooc.com//5b62d0610001badd12460576.jpg

正在回答

2 回答

我找到了答案,分享給大家。

只要修改webpack.config.js就可以打包了。

const path = require('path');? ?

const {VueLoaderPlugin}=require('vue-loader');??


????module.exports = {

????????entry: path.resolve(__dirname, "src/index.js"),? ?//webpack4官方絕對路徑

????devServer: {

????????contentBase: './dist'

????},

????output: {

????filename: 'bundle.js',

????????path: path.resolve(__dirname, 'dist')

????},

????module: {

????rules: [

????????{

test: /\.vue$/,

use: [

'vue-loader'????????

]

},

{

test: /\.css$/,

use: [

'vue-style-loader',????????????????//可以不要

'style-loader',????????????????????????

'css-loader'

]

},

]

},

plugins:[

new VueLoaderPlugin()

]

};


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

Failed at the wpc@1.0.0 build script. 這個(gè)錯(cuò)誤貌似是新版本的得在webpack.config.js加上

const VueLoaderPlugin = require('vue-loader/lib/plugin')

然后在 plugins 里面加 new VueLoaderPlugin()

不知道你的是不是因?yàn)檫@個(gè),我的已經(jīng)能跑了,都用的自動(dòng)下載的版本。(今天剛開始學(xué)vue)

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

ahswch

在 plugins 里面加 new VueLoaderPlugin() plugins 在哪啊
2018-08-11 回復(fù) 有任何疑惑可以回復(fù)我~
#2

ahswch 回復(fù) ahswch

謝謝你 這個(gè)錯(cuò)誤我弄好了 找到這個(gè)https://blog.csdn.net/cominglately/article/details/80555210 弄好的
2018-08-11 回復(fù) 有任何疑惑可以回復(fù)我~

舉報(bào)

0/150
提交
取消

老師能看一下為什么還會報(bào)錯(cuò)

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

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

幫助反饋 APP下載

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

公眾號

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