Closed Hlsgs closed 4 years ago
PostCSS is now a peer dependency, and peer dependencies don't actually get automatically installed, so you will need to install v8.x manually:
npm i --save-dev postcss
Should we start using this repo instead of the original
Yes this is the newly maintained repo. The original has been archived and is no longer maintained.
Perhaps we should ask the original developer to relinquish control of said original repo to you?
Probably won't be necessary as this is the new fork that people are gradually starting to move over to. May be a bit confusing if they then have to revert back to the original.
All good, thank you! Although I am new to your repo, your efforts are very much appreciated, kind Sir!
I took the liberty of opening https://github.com/postcss/postcss/issues/1427.
Ahh nice, thank you :)
In my case I accidentally installed grunt-postcss
instead of @lodder/grunt-postcss
. :sweat_smile:
I removed grunt-postcss because it was giving that same issue [object object], then I installed @lodder/grunt-postcss, and now I am getting this new error "jit-grunt: Plugin for the "postcss" task not found." what could be the reason?
@mindersainii I've never tested with jit-grunt
, but please bare in mind that hasn't received an update for 6 years and a stable version (1.0.0) was never released.
In your jit-grunt
config, did you set @lodder/grunt-postcss
as the task?
Something like this perhaps:
require('jit-grunt')(grunt, {
foo: '@lodder/grunt-postcss',
});
@C-Lodder Thank you for the quick response, the issue was with jit-grunt. I got rid of jit-grunt and now everything is working fine.
@mindersainii C-lodder's answer is on point. You don't need to drop jit-grunt
if you add that code.
I get this error:
Here's my package.json:
``` { "name": "XXX", "version": "1.0.0", "private": true, "browserslist": [ "> 0.5%", "last 2 versions", "Firefox ESR", "not dead", "ie 11", "android >= 4", "Edge > 12" ], "devDependencies": { "@lodder/grunt-postcss": "^3.0.0", "autoprefixer": "^10.0.0", "cssnano": "^4.1.10", "grunt": "^1.3.0", "grunt-base64": "^0.1.0", "grunt-cache-bust": "^1.7.0", "grunt-concurrent": "^3.0.0", "grunt-contrib-clean": "^2.0.0", "grunt-contrib-concat": "^1.0.1", "grunt-contrib-imagemin": "^4.0.0", "grunt-contrib-uglify": "^5.0.0", "grunt-contrib-watch": "^1.1.0", "grunt-datauri": "^0.4.0", "grunt-modernizr": "^3.0.1", "grunt-sass": "^3.1.0", "grunt-string-replace": "^1.3.1", "jit-grunt": "^0.10.0", "node-sass": "^4.14.1", "postcss-discard-comments": "^4.0.2" } } ```I am new to your plugin, comming here from the original because it started failing with the same error after updating to
Autoprefixer v10
. Should we start using this repo instead of the original? Perhaps we should ask the original developer to relinquish control of said original repo to you?