-
-
Notifications
You must be signed in to change notification settings - Fork 62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remix epic stack app: MantineProvider was not found in component tree
#480
Comments
I haven't got a chance to test it in a Remix app, so I'd like to get more feedback from people using it with Remix. Thanks! |
This is also happening in Mantine React Table (MRT) v2 alphas. But we only see it when Mantine releases a v7.x.0 version. As soon as a v7.x.1 patch is released, the error goes away. It's been the most head-scratching error I've ever seen. It's like some peer dependency is incorrect or something, and it results in multiple versions of Mantine being installed and running somehow. There are other potential causes for this error too, but this has been the weirdest and most frustrating. |
I have finally managed to test this in a simple Remix application and everything works as expected, so I cannot reproduce the error. @sid374 - can you please test with the latest versions of Mantine & Mantine DataTable, and if the problem persists, come up with a minimal reproduction (codesandbox, GitHub repo or something similar)? Thanks! |
use next js 14.1 and turborepo, same issues. |
I solved this in MRT with even more fiddling with the exports field in the package.json to make sure their were different typings specified for esm and cjs. Needed cts and mts extensions |
In case that helps anyone stumbling here, I had the same symptoms when I incorrectly installed mantine-datatable globally instead of in my project (didn't notice I was not in my project directory when running |
I was unable to reproduce it, so I'm going to close this for now. Please feel free to reopen (preferably with a reproduction) if you bump into it again. |
I'm running a Remix.run epic stack app with Mantine v7.
I have verified that I have
MantineProvider
initiated in my root route, and all my other vanillaMantine
components are getting styled and rendered correctly. However when I try to use the "Getting Started" example of mantine data table - it gives me this exception:I also tried using
useMantineTheme()
manually in my component and printing out the theme, and that works just fine too. Here's a snippet of my component:Other info
import '@mantine/core/styles.css'
. When I tried the layered approach the styles were not applied to all my other mantine components and I also got the same error on the mantine data table.I'm fairly new to the react/javascript world, and I tried my best to debug this. But I'm at a loss now, and not sure how to get to the bottom of this. Any help would be appreciated!
The text was updated successfully, but these errors were encountered: