custom extend class without tailwind keywords like fontSize,fontFamily etc..
Unanswered
West African Lion posted this in #help-forum
West African LionOP
Hi, I am trying to create custom extend in next js by importing heade.js file for component based themening where header.js is like below module.exports = {
font: {
size: "50px",
color: "#FFC300"
},
icon: {
size: "1.3rem",
color: "white"
}
}; and tailwind config file as below const customColors = require('./styles/colors');
const customFonts = require('./styles/fonts');
const components = require('./components/Header');
module.exports = {
theme: {
extend: {
colors: {
custom: customColors,
},
fontFamily: {
...customFonts.family
},
fontSize: {
...customFonts.size
},
fontWeight: {
...customFonts.weight
},
lineHeight: {
...customFonts.height
},
header:{
header:components
}
},
},
variants: {},
plugins: [],
}; How can I use those classes specificaly in my componennt Please help me out on this
font: {
size: "50px",
color: "#FFC300"
},
icon: {
size: "1.3rem",
color: "white"
}
}; and tailwind config file as below const customColors = require('./styles/colors');
const customFonts = require('./styles/fonts');
const components = require('./components/Header');
module.exports = {
theme: {
extend: {
colors: {
custom: customColors,
},
fontFamily: {
...customFonts.family
},
fontSize: {
...customFonts.size
},
fontWeight: {
...customFonts.weight
},
lineHeight: {
...customFonts.height
},
header:{
header:components
}
},
},
variants: {},
plugins: [],
}; How can I use those classes specificaly in my componennt Please help me out on this