code: function write (type, port) {
    return createAction(WRITE, writeCommand)
  
    /**
     * function that returns a write actions
     * @private
     * @param  {string} command
     * @param  {object} opts    move object
     * @return {object}         write action object
     */
    function writeCommand (command, opts) {
      return {
        type: type,
        command: command,
        opts: opts,
        port: port
      }
    }
  }
docs: curried function to return a write action creator
  @private
  @param  {string} type The type of write command
  @param  {string|array} port The port or ports that write action corresponds to
  @return {function} {@link writeCommand}