webpack4打包报错:WARNING in configuration The 'mode' option has not been set, webpack will fallback to 'production' for this value. Set 'mode' option to 'development' or 'production' to enable defaults fo
运行命令webpack ./src/main.js ./dist/murenziwei.js后,目录上神马动静都没有,你以为在dist文件夹上会有murenziwei.js吗?毛都没有

警告和错误倒是有,警告说我没有设置mode?错误说我配置打包出入口有问题?

为了快点打包成功,我老老实实的服从,将上面webpack命令改为webpack ./src/main.js --output-filename ./dist/murenziwei.js --output-path . --mode development,然后按下Enter,我的解决了,你的呢?
- --output-filename:设置要打包的文件目录
- --output-path:打包文件放置的文件目录
- --mode:告诉程序,在当前目录,我是属于开发状态development


再来最后一眼,瞧瞧murenziwei.js都有啥?

webpack4打包报错:WARNING in configuration The 'mode' option has not been set, webpack will fallback to 'production' for this value. Set 'mode' option to 'development' or 'production' to enable defaults fo的更多相关文章
- webpack4 打包报错 :regeneratorRuntime is not defined
使用async函数,在webpack打包时报错 babel-polyfill is required. You must also install it in order to get async/a ...
- android -------- 混淆打包报错(warning - InnerClass annotations are missing corresponding EnclosingMember annotations)
最近做Android混淆打包遇到一些问题,Android Sdutio 3.1 版本打包的 错误如下: Android studio warning - InnerClass annotations ...
- webpack4打包报错ERROR in multi ./src/main.js dist/bundle.js
webpack打包测试: 上边将mode01.js模块及main.js主文件编写完成,下边使用webpack对这些js文件进行打包 1.进入程序目录,执行webpack main.js build.j ...
- No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK? idea maven 打包报错问题解决
mvn clean install -X -Dmaven.test.skip=true -P dev 打包报错:No compiler is provided in this environment. ...
- maven打包报错 Fatal error compiling: tools.jar not found: C:\Program Files\Java\jre1.8.0_151\..\lib\tool
maven 打包报错 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.5.1:comp ...
- (TODO:)下载图片,报错:warning: could not load any Objective-C class information from the dyld shared cache. This will significantly reduce the quality of type information available.
想使用NSInvocationOperation下载图片,然而并没有下载下来, NSData为nil, 还有报错:(打断点就报错) warning: could not load any Object ...
- ecstore在MySQL5.7下维护报错WARNING:512 @ ALTER IGNORE TABLE
ecstore在MySQL5.7下维护报错WARNING:512 @ ALTER IGNORE TABLE 打开 /app/base/lib/application/dbtable.php , 替换A ...
- webpack 打包报错:One CLI for webpack must be installed. These are recommended choices, delivered as separate packages
webpack 打包报错: One CLI for webpack must be installed. These are recommended choices, delivered as sep ...
- Docker报错 WARNING: IPv4 forwarding is disabled. Networking will not work.
问题:创建容器的时候报错WARNING: IPv4 forwarding is disabled. Networking will not work. # docker run -it -p 3000 ...
随机推荐
- Apache Beam是什么?
Apache Beam 的前世今生 1月10日,Apache软件基金会宣布,Apache Beam成功孵化,成为该基金会的一个新的顶级项目,基于Apache V2许可证开源. 2003年,谷歌发布了著 ...
- 目录命令(tree)
TREE 命令: // 描述: 以图形方式显示驱动器中路径或磁盘的目录结构. // 语法: tree [<Drive>:][<Path>] [/f] [/a] // 参数: / ...
- 【转】C#集合类型大盘点
C#集体类型( Collections in C#) 集合是.NET FCL(Framework Class Library)中很重要的一部分,也是我们开发当中最常用到的功能之一,几乎是无处不在.俗话 ...
- jQuery基础语法
一.选择器(同css) 1.基本选择器 $("div") 通过标签名获取标签 $("#id") 通过id获取标签 $(".class") 通 ...
- 2019.02.11 bzoj4767: 两双手(组合数学+容斥dp)
传送门 题意简述:你要从(0,0)(0,0)(0,0)走到(ex,ey)(ex,ey)(ex,ey),每次可以从(x,y)(x,y)(x,y)走到(x+ax,y+ay)(x+ax,y+ay)(x+ax ...
- 2019swpuj2ee作业2--HTTP协议
简介: HTTP协议:超文本传输协议.它允许将超文本标记语言(HTML)文档从Web服务器传送到客户端的浏览器.在七层模型中属于应用层.是一种请求/响应式的协议. 主要特点: (1)支持客户端/服 ...
- Maven的多mirrors的配置
repo1 central Human Readable Name for this Mirror. http://repo1.maven.org/maven2/ repo2 central Huma ...
- django创建上下文
在app中创建context_processes.py(可以是别的名字),然后加载到settings里,这样所有的网页都可以传入变量 from .models import User def app0 ...
- 595. Big Countries --- SQL related from leetcode
595. Big Countries There is a table World +-----------------+------------+------------+------------- ...
- 856. Score of Parentheses
Given a balanced parentheses string S, compute the score of the string based on the following rule: ...