form icon indicating copy to clipboard operation
form copied to clipboard

feat(core): form listeners

Open harry-whorlow opened this issue 11 months ago β€’ 4 comments

Adds form listeners to formApi.

harry-whorlow avatar Mar 09 '25 21:03 harry-whorlow

View your CI Pipeline Execution β†— for commit 35e8458c81c74d95679a8c30cc3f6ac5aaa09a89.

Command Status Duration Result
nx affected --targets=test:sherif,test:knip,tes... βœ… Succeeded 1m 44s View β†—
nx run-many --target=build --exclude=examples/** βœ… Succeeded 22s View β†—

☁️ Nx Cloud last updated this comment at 2025-04-25 12:53:25 UTC

nx-cloud[bot] avatar Mar 09 '25 21:03 nx-cloud[bot]

More templates

@tanstack/angular-form

npm i https://pkg.pr.new/@tanstack/angular-form@1261
@tanstack/form-core

npm i https://pkg.pr.new/@tanstack/form-core@1261
@tanstack/react-form

npm i https://pkg.pr.new/@tanstack/react-form@1261
@tanstack/lit-form

npm i https://pkg.pr.new/@tanstack/lit-form@1261
@tanstack/solid-form

npm i https://pkg.pr.new/@tanstack/solid-form@1261
@tanstack/svelte-form

npm i https://pkg.pr.new/@tanstack/svelte-form@1261
@tanstack/vue-form

npm i https://pkg.pr.new/@tanstack/vue-form@1261

commit: 35e8458

pkg-pr-new[bot] avatar Mar 09 '25 21:03 pkg-pr-new[bot]

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 88.86%. Comparing base (0c79f24) to head (35e8458). Report is 8 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1261      +/-   ##
==========================================
+ Coverage   88.83%   88.86%   +0.03%     
==========================================
  Files          31       31              
  Lines        1379     1383       +4     
  Branches      347      347              
==========================================
+ Hits         1225     1229       +4     
  Misses        137      137              
  Partials       17       17              

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Mar 09 '25 21:03 codecov[bot]

Do not merge until 'infinite type' I've fixed 🀟

Screenshot 2025-03-09 at 21 58 45

harry-whorlow avatar Mar 09 '25 21:03 harry-whorlow

Note to self: move onChange out of the form listeners debounce logic and implement it in form

[edit] resolved

harry-whorlow avatar Apr 18 '25 20:04 harry-whorlow

Hey, awesome addition! If this also had debounceMs i could replace a listener i've added to all fields in a form πŸš€ (though of course it's a nit!)

MartinCura avatar Apr 27 '25 10:04 MartinCura

@MartinCura hmm that makes sense to me... would also keep it more consistent across the form and field levels, give me a day or two. πŸ˜„

harry-whorlow avatar Apr 27 '25 10:04 harry-whorlow

@MartinCura might be worth exploring TanStack Pacer in the meantime πŸ‘€

Balastrong avatar Apr 27 '25 10:04 Balastrong

@MartinCura might be worth exploring TanStack Pacer in the meantime πŸ‘€

Uuuh didn't know about that one! Though it makes sense as it looks quite new.

Don't worry, used field listeners (replacing a useDebounce from another library). Grazie! Keep up the good work (and yt channel)!

MartinCura avatar Apr 27 '25 12:04 MartinCura

@MartinCura I've implemented the debounced listeners just now... I'm waiting for a review and I'll deploy it πŸ˜„

Enjoy the weekend!

harry-whorlow avatar Apr 27 '25 12:04 harry-whorlow

@MartinCura I've implemented the debounced listeners just now... I'm waiting for a review and I'll deploy it πŸ˜„

Enjoy the weekend!

You're a machine. Danke schΓΆn !

MartinCura avatar Apr 27 '25 12:04 MartinCura

@MartinCura Kein problem, It was just deployed... enjoy the new feature!

harry-whorlow avatar Apr 27 '25 16:04 harry-whorlow