JavaScript queue implementation using linked list Are there better ways of modularizing the code? Does it contain things JavaScript experts would avoid? Is it idiomatic? Is there a better way of signaling an empty queue than returning null?

function makeQueue () {
  // types
  let Node = {
    next : null,
    data : null  
  };

  // data
  let head = null;
  let size = 0;

  // methods
  function enqueue(x) {
    let newNode = {...Node, next : head, data : x};
    head = newNode;
    size++;
  }

  function dequeue() {
    if (size === 0) {
      return null;
    }

    let x = head.data;
    head = head.next;
    size--;

    return x;
  }

  function getSize() {
    return size;
  };

  // public
  return {
    enqueue : enqueue,
    dequeue : dequeue,
    getSize : getSize
  };
};
Some observations in addition to the other answer:


inconsistent space between function name and () - use eslint or similar to prevent typos
Node is used as a template for extra properties, not as a type, so I doubt its name should be capitalized as though it's a class. Also, it's effectively unused in your code.
const in JS is not for named constants only, but for any value that's assigned just once:


  The reason is simple, it's much easier to reason about code when it is dead obvious what can change and what cannot change. [...]
  
  Going back and changing a const to a let is dead simple. And going const by default makes you think twice before doing so. And this is in many cases a good thing.
  
  How many bugs have you seen that involved variables changing unexpectedly? I'd guess a lot. I know that the majority of bugs that I see involve unexpected state changes. You won't get rid of all of these bugs by liberally using const, but you will get rid of a lot of them!


+ if you use a JavaScript IDE, it'll warn about accidental reassignment of a const identifier.
A separate assignment statement with newNode doesn't seem warranted as the code would be just as obvious with a direct assignment to head.
getSize is too verbose. I suggest exposing it as size just like the read-only size getter in Map and Set.
Since you're using ES2015, also use object literal shorthand: 

return {
  enqueue,
  dequeue,
  size: getSize
};