JavaScript/react/React.forwardRef:修订间差异

来自康健生活
Kangkk​(留言 | 贡献)
Kangkk​(留言 | 贡献)
 
(未显示同一用户的1个中间版本)
第22行: 第22行:
...
...
const FocusInput = forwardRef((props, ref) => (
const FocusInput = forwardRef((props, ref) => (
       <input type="text" ref={ref} />
       <Input ref={ref} {...props}/>
   ));
   ));
   const createTeamNameInputRef = useRef();
   const createTeamNameInputRef = useRef();
第53行: 第53行:
           footerAlign: 'right'
           footerAlign: 'right'
         })
         })
 
...
</syntaxhighlight>
</syntaxhighlight>