gpt4 book ai didi

postcss - 在包裹上发布 css autoprefixer 问题未显示前缀

转载 作者:行者123 更新时间:2023-12-03 14:49:30 35 4
gpt4 key购买 nike

Autoprefixer 不适用于parcel 1.9.7:我有我的src 文件夹,我在.postcssrc 文件内的同一文件夹内容中有.postcssrc 文件和样式文件:{ "plugins": { "autoprefixer": true } }
包裹已安装 npm install -g parcel-bundler包 json 开发依赖:

"devDependencies": {
"autoprefixer": "^9.1.3",
"node-sass": "^4.9.3",
"postcss-modules": "^1.3.2"
},

也许有人知道可能是什么问题?

最佳答案

有点晚了,但可能对其他人有帮助。
唯一有效的是把

"postcss": {
"plugins": {
"autoprefixer": {}
}

直接在 package.json 中

所以,package.json 看起来像这样:
{
"name": "parcel",
"version": "1.0.0",
"main": "index.js",
"scripts": {
"dev": "parcel src/index.html",
"prod": "parcel build src/index.html"
},
"keywords": [],
"author": "",
"license": "ISC",
"dependencies": {
"abstracts": "^0.2.3",
"postcss-modules": "^1.4.1"
},
"devDependencies": {
"autoprefixer": "^9.7.1",
"sass": "^1.23.3"
},
"postcss": {
"plugins": {
"autoprefixer": {}
}
},
"description": ""
}

关于postcss - 在包裹上发布 css autoprefixer 问题未显示前缀,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52094215/

35 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com