Minify JS embedded into .html file
What's the easiest way to get the same file with all JS snippets minified inside it?
HTML file can be arbitrarily complex and have multiple script snippets. For a number of reasons I don't need js split into separate .js files in the resulting html.
We use closure compiler and have grunt in the project.
What is Minification | Why minify JS, HTML, CSS files, dramatically improves site speed and accessibility, directly translating into a better user experience. There are many ways to do so, but in this article, we will be solely focusing on the how to minify CSS, JS, and HTML. Your website is built using a lot of files where the majority of them are HTML, CSS, and JS. These files contain tons of codes that is auto-generated or written by a developer. This makes them have size.