-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
vue-cli-service build js和css加载顺序反了 #1978
Comments
@yyx990803 |
看看是不是这个引起的 |
就是这个问题,加了下面这个配置就好了 chainConfig.plugin('html').tap(args => {
args[0].chunksSortMode = 'dependency';
return args;
}); |
webpack 4 无所谓加载顺序。 |
@yyx990803 <!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1">
<meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0">
<link href="./app.f037bd48.css" rel="stylesheet">
<link href="./chunk-vendors.b672498c.css" rel="stylesheet">
</head>
<body>
<div id="app"></div>
<script type="text/javascript" src="./js/app.af44dc52.js"></script>
<script type="text/javascript" src="./js/chunk-vendors.019f858f.js"></script>
</body>
</html> |
Fixed in 352d3bb |
In fact, the loading order of css is still has problem.
|
@PanJiaChen do you have a reproduction showing the problem post-fix? |
@yyx990803 repo: https://github.com/PanJiaChen/chunksSortMode-test When I add |
@PanJiaChen should be addressed in 495c25a ... if you don't have cyclic deps it uses the original dep sort now. |
Version
3.0.0-rc.9
Node and OS info
yarn1.7, win 10
Steps to reproduce
What is expected?
What is actually happening?
The text was updated successfully, but these errors were encountered: