code: function(line, lines, state) {
          if (!line.match(/^\s*defmodule/)) return line;
  
          state.hasModule = true;
          var lline;
          var newLine = line.replace(/^\s*defmodule\s+([\w$]+)\s+do\s*$/, 'RS_REMOVE_LINE');
  
          // ** side effect, removes last 'end'
          for (var i=1, n=lines.length; i < n; i++) {
            lline = lines[lines.length - i];
            if (lline.match('end')) {
              lines[lines.length - i] = '';
              return newLine;
            }
          }
      }
docs: removes defmodule keyword since ES6 modules don't have to be wrapped inside an object literal. Removes the last line of the module to remove dangling module `end`  state - Object used to keep state of file hasModule: Bool - flag used to prepend import  String a -> String b