typicode/mistcss

className not apply

Inaztm opened this issue · 5 comments

Generates {... props} before className.

image

Can use the cva solution or just add other classes after the "scoped" class?

Hi,

I'm not familiar with CVA, but can you try:

// CustomBlock.tsx
import { Block } from './Block.mist'

export function CustomBlock({ children, ...props }) {
  return <Block className="Block" { ...props }>children</Block>
}

@typicode

Hi.
In this example, className is ignored

image image

This is related to the ticket I added

I think It is the problem mentioned by @The-Code-Monkey indeed. The code is done so the className are PascalCase and not Camel or Kebab case.

@Inaztm could you try with a PascalCase className?

I will be fixing this tomorrow so the classname is passed through the same as people define it, but the component name will be Pascal case still