Skip to content
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

[QUESTION] Can @tsed/react-formio be used without Ts.ED framework? #117

Closed
mm-dsibinski opened this issue Mar 24, 2023 · 4 comments
Closed
Assignees
Labels
question Further information is requested

Comments

@mm-dsibinski
Copy link

mm-dsibinski commented Mar 24, 2023

Hi!
Can @tsed/react-formio be considered a better alternative to @formio/react package?
In other words: is tsed-formio somehow tied to Ts.ED framework?

I'd like to use it instead of @formio/react in a typical React project.

@mm-dsibinski mm-dsibinski added the question Further information is requested label Mar 24, 2023
@mm-dsibinski mm-dsibinski changed the title [QUESTION] Can tsed-formio be used without Ts.ED framework? [QUESTION] Can @tsed/react-formio be used without Ts.ED framework? Mar 24, 2023
@Romakita
Copy link
Contributor

Hello @mm-dsibinski
It’s totally independant of the tsed framework. It’s effectivly annalternative of react-formio ;)

@mm-dsibinski
Copy link
Author

Thanks for answering @Romakita 🙂
I checked the package, and it seems you're doing a great job here! 💪

However, I see that the React API is a bit different from original FormIO's package. Which is not a disadvantage of course, but I noticed that FormBuilder component from @tsed/react-formio expects to separately provide components and display, while the original one accepts the whole form object. It's a bit problematic for me to use now, because I also provide some custom objects there (except components and display). Unfortunately, I had to do it to "hack" around some of FormIO caveats (🤪) and it's not easy to be refactored now.

@Romakita
Copy link
Contributor

Romakita commented Mar 24, 2023

The solution is to create your component that wrap the FormEdit and FormBuilder ;)

The is the FormEdit:
https://formio.tsed.io/?path=/story/reactformio-formedit--sandbox&args=typeChoices[0].label:Form;typeChoices[0].value:form;typeChoices[1].label:Resources;typeChoices[1].value:resource;displayChoices[0].label:Form;displayChoices[0].value:form;displayChoices[1].label:Wizard;displayChoices[1].value:wizard;displayChoices[2].label:Pdf;displayChoices[2].value:pdf;enableTags:true;options.template:tailwind;options.iconset:bx

I just separated the FormBuilder from the configuration form. My FormEdit proposal is more complete but not necessarily adapted for all projects.

See you
Romain

Copy link

🎉 Are you happy?

If you appreciated the support, know that it is free and is carried out on personal time ;)

A support, even a little bit makes a difference for me and continues to bring you answers!

github opencollective

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants