please update postcss to latest
Saeeed-B opened this issue · comments
@Saeeed-B Check out the latest devel
branch and give it a spin to see if it works for you. I think it should be fine, but more testing is always good. We'll also have to make update to source-map
after this (v0.7 had some significant changes: https://github.com/mozilla/source-map/blob/master/CHANGELOG.md#070).
@StorytellerCZ How to install this branch with meteor command ؟
Just checkout the branch into your packages folder.
Or I'll make a beta release shortly.
@Saeeed-B You can try: juliancwirko:postcss@2.0.9-beta.0
We have an error in 2.0.9-beta.0 :
this is .postcssrc.js :
module.exports = ctx => {
// This flag is set when loading configuration by this package.
if (ctx.meteor) {
const config = {
plugins: {
tailwindcss: {},
autoprefixer: {},
...(ctx.env === 'production' ? { cssnano: {} } : {})
},
};
// if (ctx.env === 'production') {
// // "autoprefixer" is reported to be slow,
// // so we use it only in production.
// config.plugins.autoprefixer = {
// browsers: ['defaults'],
// };
// }
return config;
} else {
return {};
}
};
and this is tailwind.config.js :
module.exports = {
content: [
'./imports/Ui/**/*.{js,jsx,ts,tsx}',
'./imports/Routes/**/*.{js,jsx,ts,tsx}',
'./imports/**/**/*.{js,jsx,ts,tsx}',
'./public/*.{js,jsx,ts,tsx,html}'
],
darkMode: 'class', // or 'media' or 'class'
theme: {
extend: {},
},
variants: {},
plugins: [],
};
and this is package.json :
{
"name": "Ghadr",
"private": true,
"scripts": {
"start": "meteor run --settings settings.json",
"prod": "env $(cat .env | xargs) NODE_ENV=development TAILWIND_MODE='watch' meteor build ./../ --architecture os.linux.x86_64 --allow-superuser --server=https://ghadr.org",
"update": "meteor update --allow-superuser",
"update-all": "meteor update --allow-superuser --all-packages ",
"test": "meteor test --once --driver-package meteortesting:mocha",
"test-app": "TEST_WATCH=1 meteor test --full-app --driver-package meteortesting:mocha",
"visualize": "meteor --production --extra-packages bundle-visualizer",
"production": "modulus env set METEOR_SETTINGS \"$(cat settings-production.json)\" -p 'App - Production' && modulus deploy -f -p 'App - Production'"
},
"dependencies": {
"@babel/runtime": "^7.14.6",
"@loadable/component": "^5.15.0",
"bcrypt": "^5.0.1",
"browserslist": "^4.16.6",
"clsx": "^1.1.1",
"jalali-moment": "^3.3.10",
"kavenegar": "^1.1.4",
"meteor-node-stubs": "^1.1.0",
"polypay": "^1.1.1",
"postcss-load-config": "^3.1.0",
"query-string": "^7.0.1",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"react-helmet": "^6.1.0",
"react-lazy-load-image-component": "^1.5.1",
"react-redux": "^7.2.4",
"react-router-dom": "^5.2.0",
"redux": "^4.1.0",
"redux-thunk": "^2.3.0",
"suneditor": "^2.41.3",
"autoprefixer": "^10.4.0",
"postcss": "^8.4.4",
"tailwindcss": "^3.0.1"
},
"meteor": {
"mainModule": {
"client": "client/main.jsx",
"server": "server/main.js"
},
"testModule": "tests/main.js"
}
}
@StorytellerCZ Load is not a function
?
Published juliancwirko:postcss@2.1.0-beta.0 try it there as that version also includes support for Tailwind. I will try to re-create your setup next for reproduction.
I installed, tested it. Works with the tailwind and I hope you can officially release it.
Alright! Published juliancwirko:postcss@2.1.0