-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Cannot minify CSS #111
Comments
@jshster thx for the info, I will have a look into it. So you are trying to minify an empty file, right? I mean it should not make any trouble, but did you try it first with real word css? Also, you have enabled the option "minify on save", right? If you have a css which breaks, please put it in here too. If it is just an empty file, I will also have a look |
Confirming I was minifying a file with 545 lines on it. I definitely have Minify on Save set - hence why the error occurs when I save the file. Note that I copy and pasted my raw css onto a minify website and it worked perfectly. Just to be sure I just ran the file though the W3C CSS Validator and it parsed successfully, no errors. |
Unfortunately I can't reproduce it. I have now 712 lines of random CSS. I have just classes with some random stuff, no new features etc. Please identify the piece of CSS where this makes problems. I guess there is smth that probably is totally new or that new that it was not implemented into cssnano or smth else. But for now I need more info. Also please check the custom-packages, which version you have. |
And also which version of minifierbeans you have. |
Hi Chris, my apologies for the delay in responding. I am running Minifier version 3.5.0 with Netbeans 21. I just create a brand new CSS file that only contains the following: body, html { When I try to save I get (xxxx has been inserted to protect directory structures): "C:\Users\xxxx/.netbeans/minifierbeans/custom-packages/postcss.cmd" "--config" "C:\Users\xxxx/.netbeans/minifierbeans/custom-packages" "C:/xxxx/admin/css/test.css" "-o" "C:/xxxxx/admin/css/test.min.css" SyntaxError: Unexpected token '??=' I don't know how to check the version of Custom Packages I have. What should I look for? I thought I installed the same package that came with the latest version of the code but when I download the latest version and only deploy the custom-packages folder I then get a different error which seemed to indicate a mismatch in files or something (sorry didn't copy/paste it). |
And what about this? You need to go to your user folder/.netbeans/minifierbeans/custom-packages/package.json and have a look which one you have. The current working version is: 1.5.2. If not, please remove the folder custom-packages completely. |
Hey Chris, so.... I checked the package.json and it says version 1.5.1 I then downloaded the latest code and checked the package.json in the code (not the download). All of them have version 1.5.1. When I remove the custom-packages folder and then open Netbeans I then get an endless "Extracting minifierbeans archive" message in the status bar. Just to be sure here is the package.json that was active: { |
I forgot to set the latest version for Minifierbeans to 3.5.1. So please download the latest one. Also I forgot to update the repo custom-packages/package.json to version 1.5.2 which is the latest version, when you download in releases -> custom-packages. So please test it again, it seems everthing is up to date now. Versions that you need:
|
Describe the bug
When saving a css file I'm receiving the following error in the output of Netbeans:
file:///C:/Users/*****/.netbeans/minifierbeans/custom-packages/node_modules/@sindresorhus/merge-streams/index.js:60
this.#onFinished ??= onMergedStreamFinished(this, this.#streams);
^^^
SyntaxError: Unexpected token '??='
at Loader.moduleStrategy (internal/modules/esm/translators.js:145:18)
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Should minify the file
Environment (please complete the following information):
Additional context
Interestingly if I right click on the file and select Minify CSS the dialog seems to indicate that the minification has occurred - but it hasn't. Also note that JS minification works without issue.
The text was updated successfully, but these errors were encountered: