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 react ref #1463
Feat react ref #1463
Conversation
}) | ||
}, | ||
__getRefVal (key) { | ||
if (!this.__refs.current[key]) { |
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.
为啥需要这个_refs
|
||
const getDataset = (props) => { | ||
return wrapFn((resolve) => { | ||
props = props.current |
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.
为啥props得用ref包裹?
@@ -120,12 +120,16 @@ export function getDefaultOptions ({ type, rawOptions = {}, currentInject }) { | |||
rawOptions = mergeOptions(rawOptions, type, false) | |||
const components = currentInject.getComponents() || {} | |||
const validProps = Object.assign({}, rawOptions.props, rawOptions.properties) | |||
return memo((props, ref) => { | |||
return memo(forwardRef((props, ref) => { | |||
const refs = useRef({}) |
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.
这好像没有必要吧
No description provided.