whats best for perfermance inline css or styles component

for conditionnal css what the best for performace and powerful and clean code what i should to use inline css or styled cmonent
3 Replies
Coder_Carl
Coder_Carl•2y ago
It depends... 💀💀💀💀
M@HeR
M@HeROP•2y ago
i have same used card component but i have 2 mode in my app and if i use inline css i will have many condition for style if typemode?css style :new style but if i use styled i will do in 1 styled with one condition and my code will be more clean i thinks so whats your advise
Coder_Carl
Coder_Carl•2y ago
Yet again it depends. I like to pass a whole style object down as props and spread it into the component (which allows exctra classNames and attributes) when it's not common. If it is common, I typically would use a css className module that is added based on the ternary/if
Want results from more Discord servers?
Add your server