title: GraphQL optional Query Arguments
body: <p>I know you can set arguments in a schema to default values but is it possible to make the argument <code>limit</code> argument completely optional in my GraphQL Schema?</p>
  <p>Right now it seems like when I hit this without specifying a limit I think that's why I get <code>Int cannot represent non-integer value: undefined</code></p>
  <pre><code>const schema = buildSchema(`
    companies(limit: Int): [Company]
  ...)
  </code></pre>
  <p><a href="https://i.stack.imgur.com/yLF7x.jpg" rel="noreferrer"><img src="https://i.stack.imgur.com/yLF7x.jpg" alt="enter image description here" /></a></p>
  <p>I want to be able to skip the limit so that it gets all companies.</p>
  <p>In JS, I call it like this:</p>
  <pre><code>query: `query { 
            companies(limit: ${limit}) {
   ...
  </code></pre>
  <p>but sometimes I don't want to specify a limit.  So what is happening is the client is sending <code>crafters(limit: undefined)</code> and it's probably trying to convert that to Int.  I'm not sure how to not send <code>limit</code> in and how to make that entire param optional.</p>
  <p>(I also read that from the <strong>client</strong> I should be instead specifying the arguments as <strong>variables</strong> like <code>query($limit: Int) {  companies(limit: $limit) {</code> I guess from my <strong>client</strong>, from <strong>JS</strong>?  If so how would I send in my limit <strong>JS variable</strong> into that?</p>