Grunt-pure-grids生成网格单位
Grunt-pure-grids 能够生成纯网格的自定义单位的插件,它需要使用 Grunt 构建工具。
在你的项目的 Grunt 文件中,需要添加一个名为 pure_grids 的数据对象到 grunt.initConfig()中。
grunt.initConfig({
pure_grids: {
responsive: {
dest: 'path/to/my-responsive-grid.css',
options: {
units: 12, // 12-column grid
mediaQueries: {
sm: 'screen and (min-width: 35.5em)', // 568px
md: 'screen and (min-width: 48em)', // 768px
lg: 'screen and (min-width: 64em)', // 1024px
xl: 'screen and (min-width: 80em)' // 1280px
}
}
}
}
});
这是一个 12 列的纯网格
grunt.initConfig({
pure_grids: {
twelveCols: {
dest: 'path/to/my-grid.css',
options: {
units: 12, //12-column grid
}
}
}
});
评论
