alibaba / rax

🐰 Rax is a progressive framework for building universal application. https://rax.js.org
Other
7.99k stars 624 forks source link

[Question] Fusion Mobile Input 组件 hasClear 在受控状态下无效 #2168

Closed ming995 closed 3 years ago

ming995 commented 3 years ago

hasClear 如何在受控下执行,现在貌似只是支持非受控下

lianmin commented 3 years ago

能贴下复现的 demo 代码吗,如下代码是正常的

import { createElement, render } from 'rax';
import DriverUniversal from 'driver-universal';
import { Input } from '@alifd/meet';

const Demo = () => {
  return <Input placeholder="please input" defaultValue="init" hasClear />;
};

render(<Demo />, null, { driver: DriverUniversal });
ming995 commented 3 years ago

image 我使用的是 value 属性,value的值是通过别的操作获取的

lianmin commented 3 years ago

image 我使用的是 value 属性,value的值是通过别的操作获取的

能否给个完整的 demo 呢?我本地测试一下