- 
          
 - 
                Notifications
    
You must be signed in to change notification settings  - Fork 479
 
chore: optimize search performance #586
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
Conversation
| 
           This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/react-component/select/dt8dbkbw2  | 
    
          Codecov Report
 @@            Coverage Diff             @@
##           master     #586      +/-   ##
==========================================
- Coverage   99.27%   99.27%   -0.01%     
==========================================
  Files          20       20              
  Lines         967      965       -2     
  Branches      324      321       -3     
==========================================
- Hits          960      958       -2     
  Misses          6        6              
  Partials        1        1              
 Continue to review full report at Codecov. 
  | 
    
| 
           
  | 
    
          
 本地编译了一下,点了一下,正常,测试也全部通过。  | 
    
| 
           你可以在本地再试试,double check 一下  | 
    
| map.set(value, item); | ||
| }); | ||
| return map; | ||
| }, [values, options]); | 
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.
当时为啥要把 values 作为 cache 条件?
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.
不知道是咋了,今天看的时候才发现没有用到,😂
| 
           coverage 看起来掉了  | 
    
| 
           是的,代码量减少了  | 
    
| 
           需要确认的是,除了 tree-select 还有没有其他组件用到了这里的方法?我再去试试,不然害怕发个 patch 版本,有组件挂掉了?  | 
    
| 
           可以 npm link 到 antd 里,然后跑一边 test。过了就可以发了~  | 
    
| 
           antd 里面测试有问题  | 
    
          
 把编译后的文件复制到 antd 里面后好了,全部通过。  | 
    
| 
           我发个 minor 版本,antd 也升一下哈~~  | 
    
| 
           
  | 
    
fix #564
修改了
getLabeledValue里面的find改为了Map获取。影响范围:
getLabeledValue 的
prevValue改为了prevValueMaptoInnerValue 返回值 变成了两个参数
[RawValueType[], Map<RawValueType, LabelValueType>]toOuterValues 的
prevValue改为了prevValueMap@zombieJ 看看其他组件有没有用到,有没有什么影响?