
Research
Security News
The Growing Risk of Malicious Browser Extensions
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
mkdocs-minify-plugin
Advanced tools
An MkDocs plugin to minify HTML, JS or CSS files prior to being written to disk
Supply Chain Security
Vulnerability
Quality
Maintenance
License
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
An MkDocs plugin to minify HTML, JS or CSS files prior to being written to disk.
HTML minification is done using htmlmin2.
JS minification is done using jsmin.
CSS minification is done using csscompressor.
Install the plugin using pip:
pip install mkdocs-minify-plugin
Activate the plugin in mkdocs.yml
:
plugins:
- search
- minify:
minify_html: true
minify_js: true
minify_css: true
htmlmin_opts:
remove_comments: true
cache_safe: true
js_files:
- my/javascript/dir/file1.js
- my/javascript/dir/file2.js
css_files:
- my/css/dir/file1.css
- my/css/dir/file2.css
Note: If you have no
plugins
entry in your config file yet, you'll likely also want to add thesearch
plugin. MkDocs enables it by default if there is noplugins
entry set, but now you have to enable it explicitly.
minify_html
:
False
.minify_js
:
False
.True
, you must specify the JS to be minified files using js_files
(see below).minify_css
:
False
.True
, you must specify the CSS to be minified files using css_files
(see below).htmlmin_opts
:
None
.cache_safe
:
False
.True
, you must specify the files using js_files
or css_files
(see below).js_files
:
None
..min.js
in the output directory.css_files
:
None
..min.css
in the output directory.Note: When using
minify_js
orminify_css
, you don't have to modify theextra_javascript
orextra_css
entries in yourmkdocs.yml
file. The plugins automatically takes care of that. Bothminify_js
andminify_css
support the use of globs (e.g.**/*.css
).
FAQs
An MkDocs plugin to minify HTML, JS or CSS files prior to being written to disk
We found that mkdocs-minify-plugin demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
Research
Security News
An in-depth analysis of credential stealers, crypto drainers, cryptojackers, and clipboard hijackers abusing open source package registries to compromise Web3 development environments.
Security News
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.