![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
watch-less-do-more
Advanced tools
Watch less files and their dependency tree for changes & automatically recompile
Watch less files and their dependency tree for changes & automatically recompile
Rather than watching a directory for changes in any files, like other watchers, watch-less-do-more watches your main less file and automatically watches only its dependencies. If the main file, or any of it's dependencies change, the main file is compiled. This also allows you to watch multiple main files in a directory, and only compile the ones that have either changed themselves, or have had their dependencies changed. Additionally, this means that updating your node_modules (if any are dependencies of your less) will cause your less to recompile.
If we have the following files
main-a.less
main-b.less
dependency-of-a.less
dependency-of-b.less
dependency-of-a-and-b.less
not-related-to-other-files.less
And we run the command
watch-less-do-more -i main-a.less -o main-a.css -i main-b.less -o main-b.css
Changes to not-related-to-other-files.less
will not cause any less to compile.
Changes to dependency-of-a-and-b.less
will cause both main-a.less
and main-b.less
to recompile.
Changes to dependency-of-a.less
will cause only main-a.less
to recompile.
Changes to dependency-of-b.less
will cause only main-b.less
to recompile.
Install watch-less-do-more. You'll also need to install less.
Currently supports less 2.x.x
.
npm install watch-less-do-more less --save
Optionally install postcss if you want to use postcss modules.
Currently supports postcss 5.x.x
.
npm install postcss --save
In these examples we're adding a script to our package.json
{
"watch-less": "watch-less-do-more -i source.less -o output.css"
}
You can define as many files as you like, as long as there is an output argument for every input file
{
"watch-less": "watch-less-do-more -i source-a.less -o output-a.css -i source-b.less -o output-b.css"
}
You can use PostCSS modules with watch-less-do-more incredibly easily. Just install the modules you want, and tell watch-less-do-more to use them in the same way you would with PostCSS.
{
"watch-less": "watch-less-do-more -u autoprefixer -i source.less -o output.css"
}
--input, -i Path to input LESS file [string] [required]
--output, -o Path to output CSS file [string] [required]
--use, -u PostCSS module to use [string]
--help Show help [boolean]
--version Show version number [boolean]
FAQs
Watch less files and their dependency tree for changes & automatically recompile
The npm package watch-less-do-more receives a total of 37 weekly downloads. As such, watch-less-do-more popularity was classified as not popular.
We found that watch-less-do-more demonstrated a not healthy version release cadence and project activity because the last version was released 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.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.