账号密码登录
微信安全登录
微信扫描二维码登录

登录后绑定QQ、微信即可实现信息互通

手机验证码登录
找回密码返回
邮箱找回 手机找回
注册账号返回
其他登录方式
分享
  • 收藏
    X
    父组件调用子组件函数,并执行
    16
    0
    clusterize() {
          return new Clusterize({
            rows: this.DomArray,
            scrollId: this.scrollId,
            contentId: this.contentId,
            rows_in_block: this.rows_in_block,
            blocks_in_cluster: this.blocks_in_cluster,
            show_no_data_row: this.show_no_data_row,
            no_data_text: this.no_data_text,
            no_data_class: this.no_data_class,
            keep_parity: this.keep_parity,
            tag: this.tag,
    
            callbacks: (Clusterize.prototype.callbacks = {
              // 在用新的集群替换以前的集群之前会被调用。
              clusterWillChange: function() {
                console.log("在用新的集群替换以前的集群----->之前------>会被调用");
              },
              // 在用新的集群替换之前的集群后会被调用
              clusterChanged: function() {
                console.log("在用新的集群替换之前的集群----->后-------->会被调用");
              },
              // 将被调用滚动。返回进度状态
              scrollingProgress: function(progress) {
                console.log(progress);
              }
            })
          });
          
          
    
    
    1. 想给callbacks里面的函数添加回调,想父组件调用的时候可以直接传递函数,让子组件执行。
      有什么方法能够实现呢

    0
    打赏
    收藏
    点击回答
        全部回答
    • 0
    更多回答
    扫一扫访问手机版
    • 回到顶部
    • 回到顶部