File tree Expand file tree Collapse file tree 2 files changed +15
-17
lines changed
docs/samples/webpack-getting-started Expand file tree Collapse file tree 2 files changed +15
-17
lines changed Original file line number Diff line number Diff line change 99 "author" : " Shaun Luttin" ,
1010 "license" : " Apache-2.0" ,
1111 "devDependencies" : {
12- "clean-webpack-plugin" : " ^1 .0.1 " ,
13- "copy-webpack-plugin" : " ^4.6 .0" ,
14- "html-webpack-plugin" : " ^3.2 .0" ,
15- "webpack" : " ^4.29.3 " ,
16- "webpack-cli" : " ^3.2.3 " ,
17- "webpack-dev-server" : " ^3.1.14 "
12+ "clean-webpack-plugin" : " ^4 .0.0 " ,
13+ "copy-webpack-plugin" : " ^11.0 .0" ,
14+ "html-webpack-plugin" : " ^5.5 .0" ,
15+ "webpack" : " ^5.74.0 " ,
16+ "webpack-cli" : " ^4.10.0 " ,
17+ "webpack-dev-server" : " ^4.11.0 "
1818 },
1919 "dependencies" : {
20- "css-loader" : " ^2.1.0 " ,
20+ "css-loader" : " ^6.7.1 " ,
2121 "json-loader" : " ^0.5.7" ,
22- "style-loader" : " ^0.23 .1" ,
23- "swagger-ui" : " ^3.20.7 " ,
24- "yaml-loader" : " ^0.5 .0"
22+ "style-loader" : " ^3.3 .1" ,
23+ "swagger-ui" : " ^4.14.0 " ,
24+ "yaml-loader" : " ^0.8 .0"
2525 }
2626}
Original file line number Diff line number Diff line change 11const path = require ( 'path' ) ;
22const HtmlWebpackPlugin = require ( 'html-webpack-plugin' ) ;
3- const CleanWebpackPlugin = require ( 'clean-webpack-plugin' ) ;
3+ const { CleanWebpackPlugin } = require ( 'clean-webpack-plugin' ) ;
44const CopyWebpackPlugin = require ( 'copy-webpack-plugin' ) ;
55
66const outputPath = path . resolve ( __dirname , 'dist' ) ;
@@ -19,7 +19,7 @@ module.exports = {
1919 test : / \. y a m l $ / ,
2020 use : [
2121 { loader : 'json-loader' } ,
22- { loader : 'yaml-loader' }
22+ { loader : 'yaml-loader' , options : { asJSON : true } }
2323 ]
2424 } ,
2525 {
@@ -32,17 +32,15 @@ module.exports = {
3232 ]
3333 } ,
3434 plugins : [
35- new CleanWebpackPlugin ( [
36- outputPath
37- ] ) ,
38- new CopyWebpackPlugin ( [
35+ new CleanWebpackPlugin ( ) ,
36+ new CopyWebpackPlugin ( { patterns :[
3937 {
4038 // Copy the Swagger OAuth2 redirect file to the project root;
4139 // that file handles the OAuth2 redirect after authenticating the end-user.
4240 from : require . resolve ( 'swagger-ui/dist/oauth2-redirect.html' ) ,
4341 to : './'
4442 }
45- ] ) ,
43+ ] } ) ,
4644 new HtmlWebpackPlugin ( {
4745 template : 'index.html'
4846 } )
You can’t perform that action at this time.
0 commit comments