react-native-reusables icon indicating copy to clipboard operation
react-native-reusables copied to clipboard

[ BUG ] Unable to Add Form to Project Using the CLI

Open zophiana opened this issue 9 months ago • 8 comments

Describe the bug Can't add form to project. It is listed in the demo app but I cant find it in the docs neither can I add this to my project.

To Reproduce Steps to reproduce the behavior:

  1. init the project with: npx @react-native-reusables/cli@latest init
  2. try to add the form via: npx @react-native-reusables/cli@latest add form
  3. command fails

Expected behavior the command adds all the stuff needed for the form

Platform (please complete the following information): Tested with:

  • Windows 11
  • npm v22.14.0

Additional context I didn't found any information if this is just not (yet) supported or something else.

I am happy to contribute changes if there is just some stuff missing that need to be done. Please let me know!

zophiana avatar Mar 26 '25 15:03 zophiana

There is no form component currently in the rnr docs from what I can see. Not sure where the teams stands but it may be something they are interested in doing at some point.

Dillonpw avatar Mar 28 '25 20:03 Dillonpw

Ref https://github.com/mrzachnugent/react-native-reusables/blob/main/apps/showcase/app/form.tsx

caioedut avatar Apr 01 '25 16:04 caioedut

Ref https://github.com/mrzachnugent/react-native-reusables/blob/main/apps/showcase/app/form.tsx

Yes this is what I meant, it's also listed in the demo, here: https://rnr-showcase.vercel.app/form

zophiana avatar Apr 01 '25 16:04 zophiana

what error message do you get? Have you tried running the command in administrator mode using cmd?

Ammar-theScorpion avatar Apr 03 '25 06:04 Ammar-theScorpion

what error message do you get?

Those:

❯ : npx @react-native-reusables/cli@latest add form
⠋ Installing components...Invalid component(s): form

or

❯ : npx @react-native-reusables/cli@latest add forms
⠋ Installing components...Invalid component(s): forms

Have you tried running the command in administrator mode using cmd?

I would be scared if I would have to run this as root tbh. I was able to add the button, label or input components without root privileges, so I don't think this is the issue.

zophiana avatar Apr 04 '25 09:04 zophiana

@zophiana From what I can see, the form component was deprecated: #104.

IMO, this would be a nice (re)addition to the project. I don't know why it was deprecated, someone who knows could chime in, but I'd be happy to work on it.

Comment of interest: #104 (Comment)

phix-o avatar Apr 19 '25 05:04 phix-o

@zophiana From what I can see, the form component was deprecated: #104.

Thanks, yeah I think the form component also used some deprecated components. So those probably also need to be brought back

zophiana avatar Apr 21 '25 13:04 zophiana

I was able to get it to work in a project I'm working and followed a similar API to shadcn-ui's Form. I haven't thoroughly tested it yet, maybe some edge cases exists, but for what I was using it for it works.

EDIT Seems like my solution would be out of the projects scope as it relies on third party packages 😬

phix-o avatar Apr 24 '25 18:04 phix-o

As the form was deprecated, it is now removed from the project. @gabimoncha is working on a form component that uses the React Native Reusables registry.

mrzachnugent avatar Aug 22 '25 18:08 mrzachnugent

As the form was deprecated, it is now removed from the project. @gabimoncha is working on a form component that uses the React Native Reusables registry.

🫡 for those that cannot wait until September, I have a pre alpha version here https://github.com/gabimoncha/rnr-forms

gabimoncha avatar Aug 24 '25 18:08 gabimoncha

hey! any update on this? seems like gabimoncha/rnr-forms 404s

faw01 avatar Sep 06 '25 04:09 faw01

hey! any update on this? seems like gabimoncha/rnr-forms 404s

i think it's better to move any conversation regarding forms there

gabimoncha avatar Sep 07 '25 19:09 gabimoncha

hey! any update on this? seems like gabimoncha/rnr-forms 404s

i think it's better to move any conversation regarding forms there

could the repo be made public? thanks!

faw01 avatar Sep 09 '25 09:09 faw01

could the repo be made public? thanks!

i wasn't expecting this, thought it was public. change it now

gabimoncha avatar Sep 16 '25 23:09 gabimoncha