mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-01-19 14:13:34 +01:00
MinifyWorker: Delete unhelpful comment
The comment should have been a commit message instead.
This commit is contained in:
parent
a65498e849
commit
c94906f1f8
1 changed files with 0 additions and 26 deletions
|
@ -13,32 +13,6 @@ const compressJS = (content) => Terser.minify(content);
|
||||||
const compressCSS = (filename, ROOT_DIR) => new Promise((res, rej) => {
|
const compressCSS = (filename, ROOT_DIR) => new Promise((res, rej) => {
|
||||||
try {
|
try {
|
||||||
const absPath = path.resolve(ROOT_DIR, filename);
|
const absPath = path.resolve(ROOT_DIR, filename);
|
||||||
|
|
||||||
/*
|
|
||||||
* Changes done to migrate CleanCSS 3.x -> 4.x:
|
|
||||||
*
|
|
||||||
* 1. Rework the rebase logic, because the API was simplified (but we have
|
|
||||||
* less control now). See:
|
|
||||||
* https://github.com/jakubpawlowicz/clean-css/blob/08f3a74925524d30bbe7ac450979de0a8a9e54b2/README.md#important-40-breaking-changes
|
|
||||||
*
|
|
||||||
* EXAMPLE:
|
|
||||||
* The URLs contained in a CSS file (including all the stylesheets
|
|
||||||
* imported by it) residing on disk at:
|
|
||||||
* /home/muxator/etherpad/src/static/css/pad.css
|
|
||||||
*
|
|
||||||
* Will be rewritten rebasing them to:
|
|
||||||
* /home/muxator/etherpad/src/static/css
|
|
||||||
*
|
|
||||||
* 2. CleanCSS.minify() can either receive a string containing the CSS, or
|
|
||||||
* an array of strings. In that case each array element is interpreted as
|
|
||||||
* an absolute local path from which the CSS file is read.
|
|
||||||
*
|
|
||||||
* In version 4.x, CleanCSS API was simplified, eliminating the
|
|
||||||
* relativeTo parameter, and thus we cannot use our already loaded
|
|
||||||
* "content" argument, but we have to wrap the absolute path to the CSS
|
|
||||||
* in an array and ask the library to read it by itself.
|
|
||||||
*/
|
|
||||||
|
|
||||||
const basePath = path.dirname(absPath);
|
const basePath = path.dirname(absPath);
|
||||||
|
|
||||||
new CleanCSS({
|
new CleanCSS({
|
||||||
|
|
Loading…
Reference in a new issue