【发布时间】:2015-10-06 03:40:50
【问题描述】:
只要不推荐使用grunt-autoprefixer,我就想迁移到grunt-postcss。
我在 grunt 世界(和依赖项)中很新,我在文档中找不到进行迁移所需的内容。
要处理我需要三个步骤:
1- 卸载 grunt-autoprefixer
我想我必须先运行npm uninstall grunt-autoprefixer --save-dev
2- 安装 grunt-postcss
然后是npm install grunt-postcss --save-dev
但我完全不确定我是否要做npm install grunt-postcss pixrem autoprefixer-core cssnano
3- 更新配置
那我应该修改Gruntfile.js。所以实际上我有这个部分:
autoprefixer: {
options: {
browsers: ['last 1 version']
},
dist: {
files: [{
expand: true,
cwd: '.tmp/styles/',
src: '{,*/}*.css',
dest: '.tmp/styles/'
}]
}
},
我的问题:
- 能否确认卸载/安装部分?
- 如何迁移配置?
【问题讨论】: