Skip to content
This repository was archived by the owner on Aug 8, 2021. It is now read-only.

Commit 098ce2d

Browse files
committed
css in vue files to css file
1 parent db73bfb commit 098ce2d

File tree

4 files changed

+35
-16
lines changed

4 files changed

+35
-16
lines changed

.babelrc

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,16 +3,24 @@
33
[
44
"@babel/preset-env",
55
{
6-
"useBuiltIns": false,
76
"corejs": 3,
87
"modules": false,
98
"loose": false,
109
"targets": {
1110
"browsers": [
12-
">1%",
13-
"not dead",
14-
"not op_mini all",
15-
"not ie <= 11"
11+
"> 0.4%",
12+
"not IE 11",
13+
"not OperaMini all",
14+
"not IE_Mob 11",
15+
"edge >= 12",
16+
"chrome >= 30",
17+
"Samsung > 9.2",
18+
"chromeandroid >= 58",
19+
"android >= 10",
20+
"ff >= 60",
21+
"safari >= 11.1",
22+
"ios >= 11.1",
23+
"opera >= 62"
1624
]
1725
}
1826
}
@@ -23,7 +31,6 @@
2331
"@babel/plugin-transform-runtime",
2432
{
2533
"helpers": false,
26-
"corejs": false,
2734
"regenerator": true,
2835
"useESModules": false,
2936
"version": "7.0.0-beta.0",

.browserslistrc

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,13 @@
1-
defaults
2-
not IE 11
3-
not IE_Mob 11
4-
maintained node versions
1+
> 0.4%,
2+
not IE 11,
3+
not OperaMini all,
4+
not IE_Mob 11,
5+
edge >= 12,
6+
chrome >= 30,
7+
Samsung > 9.2,
8+
chromeandroid >= 58,
9+
android >= 10,
10+
ff >= 60,
11+
safari >= 11.1,
12+
ios >= 11.1,
13+
opera >= 62

webpack.dev.config.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ const UglifyJsPlugin = require('uglifyjs-webpack-plugin');
55
const HtmlWebpackPlugin = require('html-webpack-plugin');
66
const TerserJSPlugin = require('terser-webpack-plugin');
77
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
8-
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
98

109
module.exports = {
1110
entry: [
@@ -123,7 +122,6 @@ module.exports = {
123122
]
124123
},
125124
plugins: [
126-
new BundleAnalyzerPlugin(),
127125
new MiniCssExtractPlugin({
128126
filename: 'css/main.[hash:4].css',
129127
chunkFilename: 'css/[name].[hash:4].css'

webpack.prod.config.js

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,15 @@ module.exports = {
5454
},
5555
{
5656
test: /\.css$/i,
57-
loader: 'css-loader',
58-
options: {
59-
60-
},
57+
use: [
58+
{
59+
loader: MiniCssExtractPlugin.loader,
60+
options: {
61+
publicPath: '../',
62+
}
63+
},
64+
'css-loader'
65+
]
6166
},
6267
{
6368
test: /\.s(c|a)ss$/,

0 commit comments

Comments
 (0)