使用Javascript函数参数计算同一函数的另一个参数

时间:2015-11-18 11:00:45

标签: javascript jquery

function ({
  arg1: ...,
  arg2: ...,
  arg3: function() {
    return (arg1 + arg2);
  }
}) { ... };

我想知道这样的事情是否可能,如果是这样,我如何解决第三个论点中的前两个论点?

PS:以下是工作代码:

$('#fullpage').fullpage({
  scrollingSpeed: 1000,
  easingcss3: "cubic-bezier(0.39, 0.575, 0.565, 1)",
  afterLoad: function(anchorLink, index) {
    // this is the place where I want to use the scrollingSpeed and easingcss3 values
  },
});

0 个答案:

没有答案