@@ -252,7 +252,8 @@ const getEffectiveProps = (props: FormProps) => {
252252export const Form = ( props : FormProps ) => {
253253 const renderElement = useRef < HTMLDivElement | null > ( null ) ;
254254 const currentFormJson = useRef < FormType | null > ( null ) ;
255- const { formConstructor, formSource, formReadyCallback } = getEffectiveProps ( props ) ;
255+ const { formConstructor, formSource, formReadyCallback } =
256+ getEffectiveProps ( props ) ;
256257 const {
257258 src,
258259 form,
@@ -295,9 +296,10 @@ export const Form = (props: FormProps) => {
295296 console . warn ( 'Form source not found' ) ;
296297 return ;
297298 }
298- currentFormJson . current = formSource && typeof formSource !== 'string'
299- ? structuredClone ( formSource )
300- : null ;
299+ currentFormJson . current =
300+ formSource && typeof formSource !== 'string'
301+ ? structuredClone ( formSource )
302+ : null ;
301303 const instance = await createWebformInstance (
302304 formConstructor ,
303305 currentFormJson . current || formSource ,
@@ -338,7 +340,8 @@ export const Form = (props: FormProps) => {
338340 useEffect ( ( ) => {
339341 let onAnyHandler = null ;
340342 if ( formInstance && Object . keys ( handlers ) . length > 0 ) {
341- onAnyHandler = ( ...args : [ string , ...any [ ] ] ) => onAnyEvent ( handlers , ...args ) ;
343+ onAnyHandler = ( ...args : [ string , ...any [ ] ] ) =>
344+ onAnyEvent ( handlers , ...args ) ;
342345 formInstance . onAny ( onAnyHandler ) ;
343346 }
344347
0 commit comments