How to compress and merge all the js and css of the current directory to a single html file?

how do I compress and merge all the js and css of the current directory to a single html file?
our requirement is that only the html file is provided to the backend, and the backend is used for parsing. It will be troublesome to reference js/css, and what tools can be used to quickly merge and compress into a html file, and then compress html. Get what plug-ins and writing methods can be implemented with webpack and gulp? Hurry!
the structure of the project is roughly as follows: there are multiple folders, and there are corresponding styles and js, under each folder. I would like to package each folder into a html page and compress it. I would like to ask the great god who has done to share the experience of webpack configuration. Thank you!
a folder

index.html
style.css
index.js

b folder

index.html
style.css
index.js
Aug.27,2021

html-webpack-inline-source-plugin


gulp learn about

Menu