Pass a dynamic arguemetns to Meteor.call


#1

How is it possible to pass a dynamic arguments to Meteor.call ??

so sometimes I can call the methods with 3 arguments and sometimes with more than three, beacause the numbre is set from the admin;

Thanks


#2

There are a couple of simple ways to do this:

  1. Pass a single object containing the parameters. Also has the advantage that parameter order is not significant.
  2. Put your parameters into an array and use Meteor.apply instead of Meteor.call.

#3

@robfallows thank’s à lot for your help;