vyas0189 / CougarCS-Client

https://cougarcs-client.vyas0189.now.sh/
0 stars 0 forks source link

Update dependency react-hook-form to v7.13.0 #88

Closed renovate[bot] closed 3 years ago

renovate[bot] commented 3 years ago

WhiteSource Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
react-hook-form (source) 7.12.2 -> 7.13.0 age adoption passing confidence

Release Notes

react-hook-form/react-hook-form ### [`v7.13.0`](https://togithub.com/react-hook-form/react-hook-form/releases/v7.13.0) [Compare Source](https://togithub.com/react-hook-form/react-hook-form/compare/v7.12.2...v7.13.0) 🏎 Performance enhancement at scale React hook from is getting a general performance upgrade and enhancement. The following API will get big performance improvement at scale, which means it may not improve on small or medium-size applications, but rather large and complex applications with subscriptions. - `useWatch` - `useFieldArray` - `watch` - `getValues` Result Env: dev build + throttle 4x CPU + Chrome + MAC M1 | Version | Flat (1000) | Nested (1000) | Deeply Nested (1000 \* 2 \* 2000) | Flat (1000) Mount | |:--- |:---:|:---:|:---:|:---:| | `7.13.0-next.0` | 18ms | 20ms | 200ms | 470ms (no change)| | `7.11.1` | 40ms | 43ms | 2000ms | 470ms| πŸ“¦ Package size-reduction - **5%** package size reduction with compress and gzip **Total Size:** 30.3 kB | Filename | Size | Change | | |:--- |:---:|:---:|:---:| | `dist/index.cjs.js` | 8.39 kB | -445 B (5%) | βœ… | | `dist/index.esm.js` | 13.4 kB | -656 B (4%) | | | `dist/index.umd.js` | 8.52 kB | -420 B (4%) | | πŸ”« `Trigger` - Trigger will enable object name trigger and field array name trigger ```tsx useFieldArray({ name: 'test' }) trigger('name') // will trigger the whole field array to validate ``` πŸ“‘ `register` - added a `disabled` prop as an option to toggle input disable attribute - register will be able to seek input DOM reference through the `ref` callback ```tsx register('test', { disabled: true }) // will set value to undeinfed and pass disabled down to the input attribute
// this input will be registered
``` πŸ‘€ `useWatch` - added `disabled` prop to toggle the state subscription. ```tsx useWatch({ disabled: true }) // you toggle the subscription ``` ⌨️ `useFormState` - added `disabled` prop to toggle the state subscription. ```tsx useFormState({ disabled: true }) // you toggle the subscription ``` ⛳️ `setValue` - allow set value for non-registered inputs include nested object and array field. ```tsx setValue('test', [{ firstName: 'bill' }, {firstName: 'kotaro}, {firstName: 'joris'}]) // this will works ``` #### Resolved issues: ⏱️ close [#​6296](https://togithub.com/react-hook-form/react-hook-form/issues/6296) abort validation early when disable prop is detected ([#​6300](https://togithub.com/react-hook-form/react-hook-form/issues/6300)) 🎹 fix [#​6265](https://togithub.com/react-hook-form/react-hook-form/issues/6265) objects may have error messages ([#​6275](https://togithub.com/react-hook-form/react-hook-form/issues/6275)) πŸ”„ fix [#​6277](https://togithub.com/react-hook-form/react-hook-form/issues/6277) track async validate to trigger state update ([#​6284](https://togithub.com/react-hook-form/react-hook-form/issues/6284)) 🐞 fix [#​6272](https://togithub.com/react-hook-form/react-hook-form/issues/6272) only flush field array when subscription name match ([#​6281](https://togithub.com/react-hook-form/react-hook-form/issues/6281)) πŸ’ͺ🏻 simplify fillEmptyArray and combine focus name ([#​6237](https://togithub.com/react-hook-form/react-hook-form/issues/6237)) 🌡 remove redundant code for useFieldArray ([#​6236](https://togithub.com/react-hook-form/react-hook-form/issues/6236)) 🐞 patch remove, update api with key id persist ([#​6235](https://togithub.com/react-hook-form/react-hook-form/issues/6235)) 🐞 close [#​6233](https://togithub.com/react-hook-form/react-hook-form/issues/6233) for persist field array id ([#​6234](https://togithub.com/react-hook-form/react-hook-form/issues/6234)) πŸ„ enable detect fields unmount at useWatch level ([#​6226](https://togithub.com/react-hook-form/react-hook-form/issues/6226)) πŸ’¨ improve useFieldArray perf ([#​6215](https://togithub.com/react-hook-form/react-hook-form/issues/6215)) 🍨 close [#​6193](https://togithub.com/react-hook-form/react-hook-form/issues/6193) to remove shallow merge with defaultValue with watch ([#​6201](https://togithub.com/react-hook-form/react-hook-form/issues/6201)) 🐞 fix [#​6186](https://togithub.com/react-hook-form/react-hook-form/issues/6186) delayError with set error after delay ([#​6188](https://togithub.com/react-hook-form/react-hook-form/issues/6188)) β˜„οΈ enhance unregister unmount inputs by combining its logic ([#​6185](https://togithub.com/react-hook-form/react-hook-form/issues/6185)) πŸ–¨οΈ include reset clone value for array/object/date ([#​6183](https://togithub.com/react-hook-form/react-hook-form/issues/6183)) πŸ‘¨πŸ»β€πŸ”§ fix rendering order with useFieldArray ([#​6182](https://togithub.com/react-hook-form/react-hook-form/issues/6182)) 🎭 skip the shallow clone with useForm return ([#​6154](https://togithub.com/react-hook-form/react-hook-form/issues/6154)) ⌨️ fix: WatchObserver info name type ([#​6171](https://togithub.com/react-hook-form/react-hook-form/issues/6171))

Configuration

πŸ“… Schedule: At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

β™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

πŸ”• Ignore: Close this PR and you won't be reminded about this update again.



This PR has been generated by WhiteSource Renovate. View repository job log here.

vercel[bot] commented 3 years ago

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

πŸ” Inspect: https://vercel.com/vyas0189/CougarCS-Client/4gVvgAmyngqNo5fA3faxegDpG3Ty
βœ… Preview: https://cougarcs-client-git-renovate-react-hook-form-7x-vyas0189.vercel.app

sonarcloud[bot] commented 3 years ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication