Giter Club home page Giter Club logo

Comments (3)

kechen123 avatar kechen123 commented on August 26, 2024 3

如果放在onLoad里面,当数据量比较大的时候也会遇见相同的问题,这是一个性能问题。参考issues14
不知道你方便提供一下你使用该组件时的数据不,即pickerValueArray

设置无效是在第一次显示,通常是在编辑信息返显时,页面加载完成就把默认值设置上,弹出层时默认值无效,关闭后再打开会把默认值设置上。应该是必现的问题。我看了源码中是在显示时初始化的组件,我的解决方式是在设置默认值时手动调用了初始化initpicker函数,最开始我把show函数中的initpicker删除掉了,但是之后好像引发了一个bug,我又加上了。最后就是在又设置默认值的地方手动调用了一次初始化的函数

from mpvue-picker.

KuangPF avatar KuangPF commented on August 26, 2024

测试了下,当数据量比较大的时候设置默认值的确无效。如果放在 onLoad 里面,当数据量比较大的时候也会遇见相同的问题,这是一个性能问题。参考issues14
不知道你方便提供一下你使用该组件时的数据不,即 pickerValueArray

from mpvue-picker.

7obe avatar 7obe commented on August 26, 2024

组件应该加一个监控,如果pickerValueDefault变化时,应该触发initPicker函数

from mpvue-picker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.