didi / cube-ui

:large_orange_diamond: A fantastic mobile ui lib implement by Vue
https://didi.github.io/cube-ui/
Apache License 2.0
9.14k stars 1.47k forks source link

time-picker中计算属性minuteStepRule被当做methods方法使用 #821

Closed mimaster closed 1 year ago

mimaster commented 1 year ago

Version

1.12.38

Reproduction link

https://github.com/didi/cube-ui/blob/dev/src/components/time-picker/time-picker.vue

Steps to reproduce

在time-picker.vue中计算属性minuteStepRule被当做methods方法使用了

What is expected?

计算属性不应该被用作methods方法

What is actually happening?

minuteStepRule计算属性被用作methods方法

Dependencies Version

vue: 2.7.14 better-scroll: 2.4.2


查看提交记录:https://github.com/didi/cube-ui/commit/2b60d549287419f3e3faac1be8cd2056f2047d00

dolymood commented 1 year ago

你理解错了,computed只是得到了一个函数的返回值,然后接着调用的