【发布时间】:2022-01-27 08:35:28
【问题描述】:
我想将颜色变量(默认或扩展)用于我的扩展主题,例如:
module.exports = {
content: ['./index.html', './src/**/*.{js,ts,jsx,tsx}'],
theme: {
extend: {
colors: {
lime: {
'100': 'green'
}
},
backgroundColor: {
skin: {
base: 'bg-red-500',
secondary: 'lime-100',
},
},
},
},
plugins: [],
};
但这不起作用。我怎样才能有一个类bg-skin-base 相当于bg-red-500 和另一个类bg-skin-secondary 相当于bg-[green]?
【问题讨论】:
标签: tailwind-css