-
Notifications
You must be signed in to change notification settings - Fork 184
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
feat(usePatchChildren): opportunity to provide props #6135
feat(usePatchChildren): opportunity to provide props #6135
Conversation
size-limit report 📦
|
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit b0915c4:
|
e2e tests |
👀 Docs deployed
Commit b0915c4 |
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #6135 +/- ##
==========================================
+ Coverage 79.35% 79.53% +0.18%
==========================================
Files 312 313 +1
Lines 9833 9867 +34
Branches 3306 3321 +15
==========================================
+ Hits 7803 7848 +45
+ Misses 2030 2019 -11
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Филигранная работа с этими ref
. 🥇
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💠 Спасибо! 💅
Функция, которая объединяет две схожие функции в одну из двух входных параметров.
- 2-ой аргумент: добавляем возможность прокидывать параметры помимо `ref`/`getRootRef`. - 3-ий аргумент: возможность прокинуть дополнительный обработчик `ref`. В `lib/utils` добавились новые валидаторы `isDOMTypeElement()` и `isValidNotReactFragmentElement()`.
5730f67
to
b0915c4
Compare
Описание
Добавил два новых аргумента:
ref
/getRootRef
;ref
.Изменения
usePatchChildrenRef()
наusePatchChildren()
(см. feat(usePatchChildren): opportunity to provide props #6135 (comment))getMergedSameEventsByProps()
– функция, которая объединяет две схожие функции в одну из двух входныхпараметров.
lib/utils
добавились новые валидаторыisDOMTypeElement()
иisValidNotReactFragmentElement()
;