關於報錯clean-webpack-plugin:E:\workspace\ar\dist is outside of the project root. Skipping...
1.問題
webpack配置:
new CleanWebpackPlugin(['../dist'])//這裡我的webpack配置和dist不在同級目錄
執行會報錯:
clean-webpack-plugin: E:\workspace\test\dist is outside of the project root. Skipping…
2.clean-webpack-plugin介紹
用法
new CleanWebpackPlugin(paths [, {options}])
Paths (必須)
一個數組,陣列的每一個元素為要刪除的路徑
例如: [‘dist’,‘build’]
Options 和預設 (Optional)
{
"root":"[webpack.config的地址]",// 一個根的絕對路徑.
"verbose": true,// 將log寫到 console.
"dry": false,// 不要刪除任何東西,主要用於測試.
"exclude": ["files","to","ignore"]//排除不刪除的目錄,主要用於避免刪除公用的檔案
}
3.問題解決
這裡是root引數不準確導致的,可以通過如下配置解決這個問題
new CleanWebpackPlugin(['dist'], { root: path.resolve(__dirname, '../'), //根目錄 //其他配置按需求新增 })
相關推薦
關於報錯clean-webpack-plugin:E:\workspace\ar\dist is outside of the project root. Skipping...
1.問題 webpack配置: new CleanWebpackPlugin(['../dist'])//這裡我的webpack配置和dist不在同級目錄 執行會報錯: clean-webpack-plugin: E:\workspace\test\dist is outs
Vue 項目: npm run dev b報錯 “'webpack-dev-server' 不是內部或外部命令,也不是可運行的程序 或批處理文件。”
output 安裝 modules RR module -i progress his dev 前提: 電腦已經安裝了nodeJS和npm, 項目是直接下載的zip包。 報錯步驟為1:cd /d 目錄; 2. npm ren dev -------> 報錯如下:
安裝weback後,運行webpack -v報錯:‘webpack’不是內部或者外部命令
cmd命令 測試的 解決 報錯 變量 路徑 重新 原因 解析 最近,後端同事安裝webpack後,發現命令跑不起來。 原因:這位同事安裝Webpack的時候設置了全局存放路徑和緩存路徑為D盤,不在C盤的默認目錄下。 我想可能是因為這時系統接收到Webpack命令後會去C盤找
babel版本兼容報錯處理:Plugin/Preset files are not allowed to export objects
cor cin 就會 babel containe 錯誤 lpad 什麽 dex 原文地址: https://www.cnblogs.com/jiebba/p/9618930.html 1、為什麽會報錯 ? 這裏抱著錯誤是因為 babel 的版本沖突。 多是因為
android 報錯 This Gradle plugin requires a newer IDE able to request IDE model level 3 錯誤解決方案
轉載自: https://blog.csdn.net/JtooZC/article/details/79422323 android studio 匯入專案時報錯 This Gradle plugin requires a newer IDE able
webpack又報錯:BREAKING CHANGE: It's no longer allowed to omit the '-loader' suffix when using loaders.
完整錯誤資訊如下: ERROR in multi ./app/js/index.js Module not found: Error: Can't resolve 'babel' in 'E:\work
Navicat遇上MYSQL8.0報錯:Authentication plugin 'caching_sha2_password'問題的解決方案
1、進入CMD命令符視窗(win+R) 2、進入mysql安裝目錄的bin路徑下執行mysql -uroot -p命令進行登入(密碼是安裝mysql時設定的密碼) Mysql若是預設安裝路徑:則輸入cd "C:\Program Files\MySQL\MySQL Se
開啟安卓專案報錯Failed to load E:\android\android-sdk-windows\build-tools\26.0.2\lib\dx.ja Unable to build:
當我們將安卓環境成功搭建號之後,新建下一個專案準備執行時,突然發現,eclipse報錯: Failed to load (%ANDROID_SDK__HOME%)\build-tools\26.0.0
處理mysql啟動報錯Table 'mysql.plugin' doesn't exis
Installing MySQL system tables...2015-10-23 17:47:57 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_ti
啟動vue專案報錯:'webpack-dev-server' 不是內部或外部命令,也不是可執行的程式
我的操作: 1、先將自己專案中的“node_modules”檔案刪除掉。 2、如果使用的是webstorm工具,可以點選左下角的Terminal,依次輸入命令:npm install、npm run build,最後執行npm run dev後項目成功執行。(如果用的
安裝第三方庫 報錯Python version 2.7 required, which was not found in the registry
try 三方庫 64位 req not 安裝 window 是我 found 我的Windows 系統是64位 這個問題有人說是註冊表沒有 ,手動註冊了一下就好了,但是我註冊的時候運行報錯。 那麽我的做法是: 刪掉本機所有安裝過得python , 1、 先進入控制面板,刪除
Eclipse裏Tomcat報錯:Document base ……does not exist or is not a readable directory
str doc tomcat的配置 metadata tom com tor tro 路徑和 如標題所述 在eclipse中導入工程運行時提示 目錄不存在。 解決辦法: 檢查eclipse 中tomcat的配置發布路徑和 conf/server.xml 中的發布路徑
啟動weblogic報錯:string value '2.4' is not a valid enumeration value for web-app-versionType in namespace http://java.sun.com/xml/ns/javaee
-a xsd not app b- 1.0 ring encoding ont 啟動報錯: 原因:有人改動了web.xml的頭 解決方法: 在web.xml中修改擡頭為: <?xml version="1.0" encoding="UTF-8"?> <we
MongoDB的C#驅動報錯Server instance 127.0.0.1:27017 is no longer connected的解決方案
http bottom get lac soft onload nload on() kill 使用C#的MondoDB驅動,一直沒問題。結果最近,MongoCursor的ToList方法,取列表,總是報錯 Server instance 127.0.0.1:27017
VirtualBox 在WIN7 X64 安裝報錯 獲取VirtualBox COM對象失敗,Unable to start the virtual device
device class mode gis col model gist try .cn Windows Registry Editor Version 5.00 [HKEY_CLASSES_ROOT\CLSID\{00020420-0000-0000-C000-000
iOS打包上傳ipa文件時,報錯<ERROR ITMS-90096: "Your binary is not optimized for iPhone 5 - New iPhone apps......>的解決方案
splay update 分享圖片 trait tin log .com bmi graphic 很長一段時間習慣了用企業級證書發布,最近的新項目使用Xcode 9.1發布到AppStore時遇到了一個小問題(emm..其實問題跟Xcode版本沒關系,我也不知道為什麽要聲明
windows10下git報錯warning: LF will be replaced by CRLF in readme.txt. The file will have its original line endings in your working directory.
init config code 回車 git init col ngs 使用 warn window10下使用git時 報錯如下: $ git add readme.txtwarning: LF will be replaced by CRLF in readme.txt
maven的pom文件報錯: must be "pom" but is "jar"
-s 文件 pac spa err pre uil error: gin Project build error: Invalid packaging for parent POM com.test:hello-parent:0.0.1-SNAPSHOT (E:\ecli
Python import matplotlb.pyplot報錯:ImportError: No module named '_tkinter', please install the python3
Python import matplotlb.pyplot報錯:ImportError: No module named ‘_tkinter’, please install the python3 本文記錄了博主在遇到這個大坑以後重新登入Python中遇到的import matp
Spring Boo報錯Unable to start embedded container; nested exception is java.lang.NoSuchMethodError: org
轉載地址:https://www.cnblogs.com/wushuai2014/p/7497206.html 問題描述:通過Spring Boot官方提供的方式,寫出如下HelloWorld程式碼。 org.springframework.context.ApplicationContex