[WIP] Add useAppForm API to Vue#1455
Conversation
|
View your CI Pipeline Execution ↗ for commit aba6950
☁️ Nx Cloud last updated this comment at |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1455 +/- ##
==========================================
+ Coverage 90.35% 90.93% +0.57%
==========================================
Files 38 60 +22
Lines 1752 2349 +597
Branches 444 571 +127
==========================================
+ Hits 1583 2136 +553
- Misses 149 191 +42
- Partials 20 22 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Hi, I was just looking for a way to split a form in Vue (using TanStack Form) into separate fieldset components (using useAppForm). Have you by any chance already found a way to pass the form context to a fieldset component in Vue? Or maybe a way to work with just a subset of the main form? Specifically, I was trying to create a reusable fieldset for an address, so I could easily reuse it across different forms. |
|
Unfortunately we're blocked by this ATM on Vue's side: |
|
Even though it's not ideal with Vue, it might make sense to use the workaround for now — and once the Vue issue is resolved, we wouldn't need the workaround anymore. I just tested it again with your StackBlitz example, and as soon as I write |
|
No dice; Since we're in v1, introducing an API on our end requires docs, migration patterns, and more. I've considered allowing for The workaround for now - if you'd like to do that yourself until we launch - is to copy+paste the implementation of |
|
@crutchcorn However, Vue is really missing the form composition feature. I know vuejs/core#8553 blocks this, but I agree with @daniel100097 here - I think it makes sense to release it with the current limitation that requires using IMO, a limitation on the Vue side shouldn't block this feature, as this workaround is a reality of working with the Vue framework. Once the issue is resolved (or not, cause in vue you have to do the same trick for other situations, like when you use a component in computed, etc), existing code using P.S. I found that even Vue Router uses P.P.S. Also, I found that |
|
Great news here y'all: Has finally been merged! :D This means that Vue 3.6 will support our needs here and unblock the PR from moving forward. I'll be prepping this PR for merge leading up to that point |
e2648fb to
cf995c1
Compare
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🚀 Changeset Version PreviewNo changeset entries found. Merging this PR will not cause a version bump for any packages. |
|
Omg! That's such a great news! Thank you for your amazing work! |
# Conflicts: # examples/vue/array/package.json # examples/vue/simple/package.json # packages/vue-form/package.json # pnpm-lock.yaml
c1c6c21 to
5d92d4a
Compare
# Conflicts: # examples/vue/array/package.json # examples/vue/simple/package.json
# Conflicts: # examples/vue/array/package.json # examples/vue/simple/package.json # pnpm-lock.yaml
This PR adds the ability to use Form Composition APIs in our Vue adapter.
TODOs: