code: function(path) {
    var declaration = path.get('declaration');
  
    if (declaration.isFunctionDeclaration()) {
      // case of export default function compose() {}
      var id = declaration.node.id;
      if (id) {
        /*
          aligning with es modules specification
          exported identifiers have file scope (top level)
          so the declaration is split into 2 lines:
  
          function compose() {}
          module.exports = compose;
  
          this makes `compose` being hoisted
          and visible in the whole file
        */
        path.replaceWithMultiple([
          declaration.node,
          buildExportsAssignment(
            t.identifier(id.name)
          )
        ]);
      } else {
        // if the function is anonymous we can just use simpler 1 line case
        path.replaceWith(
          buildExportsAssignment(declaration)
        );
      }
    } else if (declaration.isClassDeclaration()) {
      throw path.buildCodeFrameError('Exporting ClassDeclaration is not implemented');
    } else {
      // simple case of - export default curryN;
      path.replaceWith(
        buildExportsAssignment(declaration.node)
      );
    }
  }
docs: /*
  before
  export default curryN;
  
  after
  module.exports = curryN;