const h = require('virtual-dom/h');

module.exports = function (data) {
  return h('div', {className: 'new-player'}, [
    h('form', {method: 'post', action: '/new-player/' + data}, [
      h('label', [
        'Enter your name:',
        h('input', {type: 'text', name: 'name'})
      ]),
      h('button', {type: 'submit'}, 'Join Game!')
    ])
  ]);
};

const h = require('virtual-dom/h');

module.exports = function (data) {
  return h('div', {className: 'new-player'}, [
    h('form', {method: 'post', action: '/new-player/' + data.gameID}, [
      h('label', [
        'Enter your name:',
        h('input', {type: 'text', name: 'name'})
      ]),
      h('button', {type: 'submit'}, 'Join Game!')
    ])
  ]);
};

Use object instead of string
Use object instead of string
