File tree Expand file tree Collapse file tree 2 files changed +9
-6
lines changed
packages/signals/signals/src/core/signal-generators/dom-gen Expand file tree Collapse file tree 2 files changed +9
-6
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ ' @segment/analytics-signals ' : patch
3+ ---
4+
5+ Fix circular submit error for react-hook-form
Original file line number Diff line number Diff line change @@ -140,12 +140,10 @@ const parsePropWithAttributeFallback = (
140140 return
141141 }
142142 // @ts -ignore
143- const n = element [ propName ]
144- if ( typeof n === 'string' ) {
145- return n
146- } else if ( n instanceof HTMLElement ) {
147- return element . getAttribute ( propName ) || undefined
148- }
143+ const val = element [ propName ]
144+ return typeof val === 'string'
145+ ? val
146+ : element . getAttribute ( propName ) || undefined
149147}
150148
151149export const parseElement = ( el : HTMLElement ) : AnyParsedElement => {
You can’t perform that action at this time.
0 commit comments