nuro.dev
nuro.dev copied to clipboard
Cant run build
Hi, when i try to build this i get this error
Failed to compile.
./components/Navbar/Dropdown.component.tsx:124:15
Type error: Type '{ children: ({ open }: { open: any; }) => Element; as: string; }' is not assignable to type 'IntrinsicAttributes & {
theme?: Theme; }
& { children?: ReactNode; }'.
Property 'as' does not exist on type 'IntrinsicAttributes & { theme?: Theme; } & { children?: ReactNode; }'.
122 | export function Dropdown({ children, items, position }: StandardProps) {
123 | return (
> 124 | <StyledMenu as="div">
| ^
125 | {({ open }) => (
126 | <>
127 | <Menu.Button as={Fragment}>{children}</Menu.Button>
Appreciate any help!
Same here
Thanks for reporting this issue.
I've come across this error a few times in the past few weeks & am yet to find an exact cause other than some fault with the yarn.lock
& the Babel / Emotion dependencies.
I would like to find the true cause of this eventually, but currently I am in the process of moving away from Emotion.css in favour of purely using Windi CSS instead. See #53
On the last merge, the error when i try to build is:
Type error: Type '(options?: void | Options) => void | Transformer<Root, Root>' is not assignable to type 'Plugin<[Settings?], Settings>'.
Type 'void | Transformer<Root, Root>' is not assignable to type 'void | Transformer'.
Type 'Transformer<Root, Root>' is not assignable to type 'void | Transformer'.
Type 'Transformer<Root, Root>' is not assignable to type 'Transformer'.
Types of parameters 'file' and 'file' are incompatible.
Type 'VFile' is missing the following properties from type 'VFile': value, stored, result, map
59 | scope: data,
60 | mdxOptions: {
> 61 | rehypePlugins: [[RehypeAutolinkHeadings, {}]],
| ^
62 | remarkPlugins: [RemarkCodeTitles, RemarkEmoji, RemarkPrism, RemarkSlug],
63 | },
64 | });
I have tried but I am unable to reproduce this locally, no is CD showing this issue.
Are you able to re-install your node_modules
to verify it's not a outdated dependency issue?
i tried to delete node_modules folder and install the dependencies again, but it's still showing that error. I'll try to figure out what is happening if you want.