I could not wait to finally try Mantine integration so I upgraded to v3.0.0 RC to try it out. I have few findings that I would like to share and hear your opinion. Some of them are potential issues to be reported (I can report it if you confirm):
Add mantine as option in CLI section of Reference docs (docs/cli-commands#setup-ui):
This one is a low-hanging fruit but, just to remind. If needed, I can report it as issue and provide PR. Need to check docs into more detail
Form approach when using mantine:
Mantine provides own form helper that, somehow, differs from Redwood approach even it seems that both of them rely on same lib under the hood. Now, with this one Iām in doubt: from one side, when I first bump into Redwood, I was astonished by forms approach (and, in general, I like to keep things simple and as close as I can to āoriginal ideaā. However, it seems that Mantine forms approach is as simple as RW but, integrated better with mantine-core controls (or, from other side, mantine-core controls are better fitted to mantine-form). So, I would like to ask is some kind of rw-mantine adapter for forms (e.g. to use mantine controls on RW way) is provided with RC (or it is planned in the future) and how to get more info about it (example, tutorials, whatever).
Mantine use-form hook breaks Storybook
I bumped into this one as follow-up of previous question. So, I tried to add mantin form and controls to simple demo page (contact page from tutorial). I noticed that, when I just import useForm from Mantine (import { useForm } from '@mantine/form), page disappears from Storybook (disspears: no page in side menu, 'Couldnāt find story matching āpages-contactpageāgeneratedā error message if I try to go to link directly.
As I mentioned, Iām in love with both Redwood and Mantine so I will probably continue to dig into this topic. I will try to list any new findings in this thread, as reference. And, did I forget to say big āTHANK YOUā for guys that integrated Mantine into RW?
Ok, I resolved this one: @mantine/form is not installed for web-side so I added it manually and it works now. Weird that I didnāt get any errors or warnings during SB rebuild. However, it is up to authors to decide should āformā package be in default part of mantine integration or it should be added āper needā (and, documented somwhere)
Please do open a PR. It sounds pretty straight forward, so no need to open an issue first. Just make sure to write a good PR description and we should be able to merge it
Nothing exists right now, and nothing is on our roadmap. No pressure, or expectations, but if you wanted to experiment and see what approach you think would work best, and then write a post on the forums that would be of tremendous value to the entire community! And from there we could see if we wanted to try to provide some wrapper/adapter lib or something.
Documentation could be a good first step here. Another option we could also consider is to add a prompt to the setup step, asking if forms support should be added or not. In the future that could then also install the adapter library from no2 above.
Please let us all know what you think about the steps above, and if you want to work on any of them
I went to create PR but then noticed that fix is already present on Main branch (will became available on docs with 3.0.0. full release)
I can try to experiment a bit and try to find some ideas. Until then, it seems that replacing āredwood wayā with Mantine should do the job (again, pitty for all nice rw components)
Sound like a nice idea. However, since adding @mantine/form is quite trivial and usually done by people that know why they need the package, maybe just adding a note to the documentation would be easier approach (suggestion: āMantine support does not provide Mantineās Form support out of the box. If you need to use Mantine forms, add @mantine/form manually to your web sideā
I can do it but, question is where to document it? As a side note on docs/cli-commands#setup-ui or there is a separate documentation for Mantine integration? Iām somehow concerned that adding such āintegration-specificā detail to (should be) high-level CLI docs can open a āpandoras boxā regarding documentation readability? However, just point me where I should add it and I will do it.
This is a very valid concern. That would have happened with auth (https://redwoodjs.com/docs/cli-commands#setup-auth), so we moved all of that to its own section instead. I think we can start with a āUsageā section in the cli docs for UI. And then if it grows too big or detailed we can extract it out to its own section later. How does that sound to you?
@zbubric
I am a newbie here and to Redwood forms, but when I was fighting with custom Select I did happen to find Mantine and was able to connect it to the RedwoodJS form⦠I had an issue with GraphQL and I have not tried it since resolving it.
But apart from that GraphQL issue it did work quite nicely. Can you explain the issue a bit (and maybe how it differs from throwing Mantine manually and using <Controller> component? Only if you think itās useful for othersā¦
I will be trying Mantine in 3.0 rc as well since it looks great and very complete (and is very, very customizable from what I have seen (1 component but still)).
Iām trying to prepare a showcase project containing both āvanillaā approaches (pure RW and pure Mantine Form) as well as some potential āadaptersā (or, at least, a starting point to play with different approaches).
Hope that I will find some time during the weekend to publish first part on github so we can use it as a base-point for further ideas and approaches.
Hi guys,
just to let you know that I, beside lack of time due to regular job pressure, a bit late with this one because I bumped into some new questions, some of them mantine and form related and some are just basic stuff (that is good to refresh knowledge a bit).
As soon as I have something usable, I will share a github link