Loading ...
Sorry, an error occurred while loading the content.

[jslint] Re: "unnamed" Parameter Option

Expand Messages
  • sandyhead25
    Could you rephrase that? I am not sure what you are asking.
    Message 1 of 9 , Sep 22, 2011
    • 0 Attachment
      Could you rephrase that? I am not sure what you are asking.

      --- In jslint_com@yahoogroups.com, Xavier MONTILLET <xavierm02.net@...> wrote:
      >
      > I don't get the point of removing arguments if it forces you to ask for an
      > array as argument...
      >
      > On Wed, Sep 21, 2011 at 7:04 PM, sandyhead25 <austin.cheney@...>wrote:
      >
      > > **
      > >
      > >
      > > Simple. Change the format of input to an object literal. Then you can have
      > > a variable number of named parameters. Consider the following:
      > >
      > > var args = {first: "x", second: "y", third: "z"},
      > > mycode = function (args) {
      > > //args.first === "x";
      > > };
      > >
      > > Here is an actual living example from a real application:
      > > https://github.com/austincheney/Pretty-Diff/blob/master/markup_beauty.js
      > >
    Your message has been successfully submitted and would be delivered to recipients shortly.