A lightweight Node.js minifier for CSS and JS files with a simple API and CLI mode. Version 1.0.5 is the latest stable release. It recursively finds all CSS and JS files in a given directory and minifies them using clean-css (v4.2.1) and UglifyJS3 (v3.6.8). Differentiators: minimal configuration, zero-fuss operation (just call a function), and support for custom options for both minifiers. Primarily for quick build scripts or small projects.
npm install simply-minifyNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows basic usage: require, call with no arguments (defaults to ./dist), and with custom directory and minifier options.
Call simplyMinify(dir, cssOptions, jsOptions) in order.
Use 'simplyMinify <path>' in terminal.
Use require() instead of import.
Ensure only intended files are in the target directory or use a subdirectory.
Consider using an alternative minifier or updating the package if newer versions are released.
const simplyMinify = require('simply-minify');Install globally: npm install -g simply-minify and use 'simplyMinify' (camelCase).
Create the folder or pass a valid directory as the first argument.
Refer to clean-css documentation for valid options, e.g., { level: { 1: { specialComments: 'none' } } }.